Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e5e46e0

Browse files
committed
Fixed embarrassing logic bug in read_lines_to_outerboundary().
1 parent 2caac73 commit e5e46e0

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

Lib/cgi.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,7 @@
399399

400400
# " <== Emacs font-lock de-bogo-kludgificocity
401401

402-
__version__ = "2.0b3"
402+
__version__ = "2.0b4"
403403

404404

405405
# Imports
@@ -891,6 +891,7 @@ def read_lines_to_outerboundary(self):
891891
if strippedline == last:
892892
self.done = 1
893893
break
894+
odelim = delim
894895
if line[-2:] == "\r\n":
895896
delim = "\r\n"
896897
line = line[:-2]
@@ -899,7 +900,7 @@ def read_lines_to_outerboundary(self):
899900
line = line[:-1]
900901
else:
901902
delim = ""
902-
self.file.write(delim + line)
903+
self.file.write(odelim + line)
903904

904905
def skip_lines(self):
905906
"""Internal: skip lines until outer boundary if defined."""

0 commit comments

Comments
 (0)