diff --git a/fdroidserver/scanner.py b/fdroidserver/scanner.py index 5587bd4b..ab410301 100644 --- a/fdroidserver/scanner.py +++ b/fdroidserver/scanner.py @@ -191,7 +191,8 @@ def scan_source(build_dir, root_dir, thisbuild): if is_used_by_gradle(line): for name in suspects_found(line): count += handleproblem('usual supect \'%s\' at line %d' % (name, i+1), fd, fp) - joined = re.sub(r'[\n\r\s]+', ' ', ' '.join(lines)) + noncomment_lines = [l for l in lines if not common.gradle_comment.match(l)] + joined = re.sub(r'[\n\r\s]+', ' ', ' '.join(noncomment_lines)) for m in gradle_mavenrepo.finditer(joined): url = m.group(2) if not any(r.match(url) for r in allowed_repos):