rstrip header field names in relaxed, as the spec says.

This commit is contained in:
William Grant
2011-06-03 22:03:41 +10:00
parent 61cd0e1080
commit 5da23e5856
+1 -1
View File
@@ -66,7 +66,7 @@ class Relaxed:
# Compress WSP to single space.
# Remove all WSP at the start or end of the field value (strip).
return [
(x[0].lower(),
(x[0].lower().rstrip(),
compress_whitespace(unfold_header_value(x[1])).strip() + b"\r\n")
for x in headers]