Handle failing git command in check_copyright.py

pull/5157/head
murgatroid99 9 years ago
parent f656f189e4
commit c58a781ba2
  1. 10
      tools/distrib/check_copyright.py

@ -131,8 +131,14 @@ def log(cond, why, filename):
# scan files, validate the text
ok = True
for filename in subprocess.check_output(FILE_LIST_COMMAND,
shell=True).splitlines():
filename_list = []
try:
filename_list = subprocess.check_output(FILE_LIST_COMMAND,
shell=True).splitlines()
except subprocess.CalledProcessError:
sys.exit(0)
for filename in filename_list:
if filename in KNOWN_BAD: continue
ext = os.path.splitext(filename)[1]
base = os.path.basename(filename)

Loading…
Cancel
Save