mirror of
https://github.com/python/cpython.git
synced 2025-10-10 00:43:41 +00:00
bpo-27737: Allow whitespace only headers encoding (#13478)
This commit is contained in:
parent
6bc5917903
commit
ef5bb25e2d
3 changed files with 6 additions and 1 deletions
|
@ -431,7 +431,7 @@ class _ValueFormatter:
|
|||
if end_of_line != (' ', ''):
|
||||
self._current_line.push(*end_of_line)
|
||||
if len(self._current_line) > 0:
|
||||
if self._current_line.is_onlyws():
|
||||
if self._current_line.is_onlyws() and self._lines:
|
||||
self._lines[-1] += str(self._current_line)
|
||||
else:
|
||||
self._lines.append(str(self._current_line))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue