Commit 33975eac authored by Barry Warsaw's avatar Barry Warsaw

_split_ascii(): lstrip the individual lines in the ascii split lines,

since we'll be adding our own continuation whitespace later.
parent 28ffcef4
...@@ -416,6 +416,9 @@ def _split_ascii(s, firstlen, restlen, continuation_ws, splitchars): ...@@ -416,6 +416,9 @@ def _split_ascii(s, firstlen, restlen, continuation_ws, splitchars):
lines = [] lines = []
maxlen = firstlen maxlen = firstlen
for line in s.splitlines(): for line in s.splitlines():
# Ignore any leading whitespace (i.e. continuation whitespace) already
# on the line, since we'll be adding our own.
line = line.lstrip()
if len(line) < maxlen: if len(line) < maxlen:
lines.append(line) lines.append(line)
maxlen = restlen maxlen = restlen
......
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