mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-15 23:42:37 +03:00
Don't crash if AM.xml has no application element
This commit is contained in:
parent
97a637b9b4
commit
3a616e2d9f
1 changed files with 2 additions and 0 deletions
|
@ -968,6 +968,8 @@ def fetch_real_name(app_dir, flavours):
|
||||||
logging.debug("fetch_real_name: Checking manifest at " + path)
|
logging.debug("fetch_real_name: Checking manifest at " + path)
|
||||||
xml = parse_xml(path)
|
xml = parse_xml(path)
|
||||||
app = xml.find('application')
|
app = xml.find('application')
|
||||||
|
if app is None:
|
||||||
|
continue
|
||||||
if "{http://schemas.android.com/apk/res/android}label" not in app.attrib:
|
if "{http://schemas.android.com/apk/res/android}label" not in app.attrib:
|
||||||
continue
|
continue
|
||||||
label = app.attrib["{http://schemas.android.com/apk/res/android}label"].encode('utf-8')
|
label = app.attrib["{http://schemas.android.com/apk/res/android}label"].encode('utf-8')
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue