Skip to content

Commit

Permalink
pep8 fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasjfox committed Jan 8, 2015
1 parent 6a8293a commit ced089b
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions triage/triage-report.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@

f = open(project + '/true-positives.txt', 'rt')
truepositives = f.read()
f.close();
f.close()

f = open(project + '/false-positives.txt', 'rt')
falsepositives = f.read()
f.close();
f.close()

fin = open(resultfile,'rt')
fin = open(resultfile, 'rt')
results = fin.read()
fin.close()

Expand All @@ -36,7 +36,7 @@
result = result.strip()

res = re.match('\\[('+project+'.+):([0-9]+)\\]:\s+[(][a-z]+[)] (.+)', result)
if res == None:
if res is None:
continue

filename = res.group(1)
Expand All @@ -58,7 +58,7 @@
html += '<td class='+css+'>'+filename+'</td>'
html += '<td class='+css+'>'+linenr+'</td>'
html += '<td class='+css+'>'+message+'</td>'
if project=='linux-3.11':
if project == 'linux-3.11':
href = 'http://github.com/torvalds/linux/blob/v3.11' + filename[filename.find('/'):] + '#L' + linenr
if href:
html += '<td class='+css+'><a href="' + href + '">' + classification + '</a></td>'
Expand All @@ -75,7 +75,7 @@
continue

res = re.match('\\[('+project+'.+):([0-9]+)\\]:\s+[(][a-z]+[)] (.+)', line)
if res == None:
if res is None:
continue

if line in results:
Expand All @@ -98,15 +98,15 @@

out[css] += html

f.close();
f.close()

project2 = ''
if project.find('-') > 0:
project2 = project[:project.find('-')]
else:
project2 = project

fout = open('report.html','wt')
fout = open('report.html', 'wt')
fout.write('<html><head><title>Cppcheck results for ' + project + '</title><link rel="stylesheet" type="text/css" href="theme1.css"></head><body>\n')
fout.write('<h1>Cppcheck results for ' + project + '</h1>\n')
fout.write('<p>Number of false negatives: ' + str(numberOfFalseNegatives) + '</p>\n')
Expand Down

0 comments on commit ced089b

Please sign in to comment.