mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-16 16:02:33 +03:00
Fix: some apks have a zip mimetype instead of a jar one
This commit is contained in:
parent
5c483a5484
commit
b92b722c6d
1 changed files with 6 additions and 3 deletions
|
@ -1279,13 +1279,16 @@ def scan_source(build_dir, root_dir, thisbuild):
|
||||||
count += handleproblem('binary executable', fd, fp)
|
count += handleproblem('binary executable', fd, fp)
|
||||||
elif mime == 'application/x-java-applet':
|
elif mime == 'application/x-java-applet':
|
||||||
count += handleproblem('Java compiled class', fd, fp)
|
count += handleproblem('Java compiled class', fd, fp)
|
||||||
elif mime == 'application/jar' and has_extension(fp, 'apk'):
|
elif has_extension(fp, 'apk') and mime in (
|
||||||
|
'application/jar',
|
||||||
|
'application/zip',
|
||||||
|
):
|
||||||
removeproblem('APK file', fd, fp)
|
removeproblem('APK file', fd, fp)
|
||||||
elif has_extension(fp, 'jar') and mime in [
|
elif has_extension(fp, 'jar') and mime in (
|
||||||
'application/zip',
|
'application/zip',
|
||||||
'application/java-archive',
|
'application/java-archive',
|
||||||
'binary',
|
'binary',
|
||||||
]:
|
):
|
||||||
warnproblem('JAR file', fd)
|
warnproblem('JAR file', fd)
|
||||||
elif mime == 'application/zip':
|
elif mime == 'application/zip':
|
||||||
warnproblem('ZIP file', fd)
|
warnproblem('ZIP file', fd)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue