From: Barry Warsaw Date: Thu, 13 May 2004 20:14:20 +0000 (+0000) Subject: _structure(): Make sure all output goes the to fp object. X-Git-Tag: v2.4a1~379 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d49f1d6c5aa30ce441a976eee7e7dca0a06f1e19;p=python _structure(): Make sure all output goes the to fp object. --- diff --git a/Lib/email/Iterators.py b/Lib/email/Iterators.py index 2572c205be..af6095e7c7 100644 --- a/Lib/email/Iterators.py +++ b/Lib/email/Iterators.py @@ -59,9 +59,9 @@ def _structure(msg, fp=None, level=0, include_default=False): tab = ' ' * (level * 4) print >> fp, tab + msg.get_content_type(), if include_default: - print '[%s]' % msg.get_default_type() + print >> fp, '[%s]' % msg.get_default_type() else: - print + print >> fp if msg.is_multipart(): for subpart in msg.get_payload(): _structure(subpart, fp, level+1, include_default)