Commit f6aaf845 authored by Guido van Rossum's avatar Guido van Rossum

Fixed embarrassing logic bug in read_lines_to_outerboundary().

parent 7e2edeb7
...@@ -399,7 +399,7 @@ backwards compatible and debugging classes and functions? ...@@ -399,7 +399,7 @@ backwards compatible and debugging classes and functions?
# " <== Emacs font-lock de-bogo-kludgificocity # " <== Emacs font-lock de-bogo-kludgificocity
__version__ = "2.0b3" __version__ = "2.0b4"
# Imports # Imports
...@@ -891,6 +891,7 @@ class FieldStorage: ...@@ -891,6 +891,7 @@ class FieldStorage:
if strippedline == last: if strippedline == last:
self.done = 1 self.done = 1
break break
odelim = delim
if line[-2:] == "\r\n": if line[-2:] == "\r\n":
delim = "\r\n" delim = "\r\n"
line = line[:-2] line = line[:-2]
...@@ -899,7 +900,7 @@ class FieldStorage: ...@@ -899,7 +900,7 @@ class FieldStorage:
line = line[:-1] line = line[:-1]
else: else:
delim = "" delim = ""
self.file.write(delim + line) self.file.write(odelim + line)
def skip_lines(self): def skip_lines(self):
"""Internal: skip lines until outer boundary if defined.""" """Internal: skip lines until outer boundary if defined."""
......
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