mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-06 07:20:29 +03:00
Don't try reading lines from directories
This commit is contained in:
parent
d1d257bef4
commit
3f9d6b2947
2 changed files with 6 additions and 0 deletions
|
|
@ -434,6 +434,8 @@ def adapt_gradle(build_dir):
|
|||
if not filename.endswith('.gradle'):
|
||||
continue
|
||||
path = os.path.join(root, filename)
|
||||
if not os.path.isfile(path):
|
||||
continue
|
||||
logging.debug("Adapting %s at %s" % (filename, path))
|
||||
|
||||
FDroidPopen(['sed', '-i',
|
||||
|
|
|
|||
|
|
@ -1312,6 +1312,8 @@ def prepare_source(vcs, app, build, build_dir, srclib_dir, extlib_dir, onserver=
|
|||
if not filename.endswith('.gradle'):
|
||||
continue
|
||||
path = os.path.join(dir_path, filename)
|
||||
if not os.path.isfile(path):
|
||||
continue
|
||||
for line in file(path):
|
||||
match = version_regex.match(line)
|
||||
if match:
|
||||
|
|
@ -1588,6 +1590,8 @@ def scan_source(build_dir, root_dir, thisbuild):
|
|||
warnproblem('unknown compressed or binary file', fd)
|
||||
|
||||
elif has_extension(fp, 'java') and os.path.isfile(fp):
|
||||
if not os.path.isfile(fp):
|
||||
continue
|
||||
for line in file(fp):
|
||||
if 'DexClassLoader' in line:
|
||||
count += handleproblem('DexClassLoader', fd, fp)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue