INNER CODE UNIT · Python
found_simple_format
f-droid/fdroidclient · tools/check-format-strings.py:38
found_simple_format = False # %s
found_numbered_format = False # %1$s
if e.text is None:
fulltext = re.sub(r' *<string name="' + e.attrib['name'] + r'"> *</string> *\n?', '', fulltext)
print('%s: %s is blank!' % (str_path, e.attrib['name']))
count += 1
continue
for m in formatRe.finditer(e.text):
s = m.group(0)
if simpleFormatRe.match(s):
found_simple_format = True
if numberedFormatRe.match(s):
found_numbered_format = True
if validFormatRe.match(s):
continue
count += 1
print('%s: Invalid format "%s" in "%s"' % (str_path, s, e.text))