it's possible to hit the finally with no f
This commit is contained in:
parent
1d332c915e
commit
b79c62ef49
4
setup.py
4
setup.py
|
@ -79,6 +79,7 @@ class Uninstall(Command):
|
||||||
return 'uninstall'
|
return 'uninstall'
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
|
f = None
|
||||||
self.ensure_filename('manifest')
|
self.ensure_filename('manifest')
|
||||||
try:
|
try:
|
||||||
try:
|
try:
|
||||||
|
@ -87,7 +88,8 @@ class Uninstall(Command):
|
||||||
except IOError, e:
|
except IOError, e:
|
||||||
raise DistutilsFileError("unable to open install manifest: %s", str(e))
|
raise DistutilsFileError("unable to open install manifest: %s", str(e))
|
||||||
finally:
|
finally:
|
||||||
f.close()
|
if f:
|
||||||
|
f.close()
|
||||||
|
|
||||||
for file in files:
|
for file in files:
|
||||||
if os.path.isfile(file) or os.path.islink(file):
|
if os.path.isfile(file) or os.path.islink(file):
|
||||||
|
|
Loading…
Reference in New Issue