Fix #12811 by closing files promptly in tabnanny.check. Patch by Anthony Briggs.

This commit is contained in:
Nick Coghlan 2011-08-22 16:19:19 +10:00
parent 029ba2b8cd
commit c4a287114e
3 changed files with 7 additions and 0 deletions

View file

@ -126,6 +126,9 @@ def check(file):
else: print(file, badline, repr(line))
return
finally:
f.close()
if verbose:
print("%r: Clean bill of health." % (file,))