summaryrefslogtreecommitdiff
path: root/Lib/email/Header.py
diff options
context:
space:
mode:
authorTim Peters <tim.peters@gmail.com>2002-05-23 15:15:30 +0000
committerTim Peters <tim.peters@gmail.com>2002-05-23 15:15:30 +0000
commit8ac1495a6a1d18111a626cec0c7f2eb67df3edb3 (patch)
tree2d91993770d3a5b3f3668857983d9bf75276b14f /Lib/email/Header.py
parentf655328483b2e237cc2f71c1c308eceb2f30f6fd (diff)
downloadcpython-git-8ac1495a6a1d18111a626cec0c7f2eb67df3edb3.tar.gz
Whitespace normalization.
Diffstat (limited to 'Lib/email/Header.py')
-rw-r--r--Lib/email/Header.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/Lib/email/Header.py b/Lib/email/Header.py
index fb8792cb36..95b5a37611 100644
--- a/Lib/email/Header.py
+++ b/Lib/email/Header.py
@@ -61,7 +61,7 @@ def decode_header(header):
if not ecre.search(line):
decoded.append((line, None))
continue
-
+
parts = ecre.split(line)
while parts:
unenc = parts.pop(0).strip()
@@ -149,14 +149,14 @@ class Header:
if charset is None:
charset = self._charset
self._chunks.append((s, charset))
-
+
def _split(self, s, charset):
# Split up a header safely for use with encode_chunks. BAW: this
# appears to be a private convenience method.
splittable = charset.to_splittable(s)
encoded = charset.from_splittable(splittable)
elen = charset.encoded_header_len(encoded)
-
+
if elen <= self._maxlinelen:
return [(encoded, charset)]
# BAW: should we use encoded?
@@ -185,7 +185,7 @@ class Header:
Base64 or quoted-printable) header strings. In addition, there is a
75-character length limit on any given encoded header field, so
line-wrapping must be performed, even with double-byte character sets.
-
+
This method will do its best to convert the string to the correct
character set used in email, and encode and line wrap it safely with
the appropriate scheme for that character set.