Commit f55d96fa authored by Éric Araujo's avatar Éric Araujo

Fix resource warning found manually

parent 623c67f8
......@@ -294,17 +294,20 @@ class sdist(Command):
join_lines=1, lstrip_ws=1, rstrip_ws=1,
collapse_join=1)
while True:
line = template.readline()
if line is None: # end of file
break
try:
self.filelist.process_template_line(line)
except DistutilsTemplateError as msg:
self.warn("%s, line %d: %s" % (template.filename,
template.current_line,
msg))
try:
while True:
line = template.readline()
if line is None: # end of file
break
try:
self.filelist.process_template_line(line)
except DistutilsTemplateError as msg:
self.warn("%s, line %d: %s" % (template.filename,
template.current_line,
msg))
finally:
template.close()
def prune_file_list(self):
"""Prune off branches that might slip into the file list as created
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment