Assignment before use (if Enumerate fails)

This commit is contained in:
Alexandre Dulaunoy 2014-08-18 15:58:06 +02:00
parent ebef13fa5b
commit 7d8ee102a3

View file

@ -117,6 +117,7 @@ class Paste(object):
if self.p_nb_lines is None or self.p_max_length_line is None:
max_length_line = 0
f = self.get_p_content_as_file()
line_id = 0
for line_id, line in enumerate(f):
length = len(line)
if length >= max_length_line: