daca2: fixed exitcode handling

This commit is contained in:
Daniel Marjamäki 2013-12-31 20:56:16 +01:00
parent 56a5b0d55f
commit 5d31385161
1 changed files with 3 additions and 2 deletions

View File

@ -166,8 +166,9 @@ def scanarchive(filepath):
comm = p.communicate()
results = open('results.txt', 'at')
if p.returncode == 0:
results.write(comm[1])
if p.returncode != 0:
elif comm[0].find('cppcheck: error: could not find or open any of the paths given.') < 0:
results.write('Exit code is not zero! Crash?\n')
results.write('\n')
results.close()