Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

BUG archive not closed on key error

  • Loading branch information...
commit 31b809de32c8ecae1d9cd0c4ba8d89270945aa46 1 parent 52abcb8
@kwgoodman authored
Showing with 2 additions and 0 deletions.
  1. +2 −0  la/io.py
View
2  la/io.py
@@ -168,9 +168,11 @@ def __getitem__(self, key):
x = lara(self.filename, key)
return x
else:
+ f.close()
msg = "%s is in the archive but it is not a larry."
raise KeyError(msg % key)
else:
+ f.close()
raise KeyError("A larry named %s is not in the archive." % key)
def __setitem__(self, key, value):
Please sign in to comment.
Something went wrong with that request. Please try again.