From: Sean Reifscheider Date: Sat, 20 Mar 2010 00:06:05 +0000 (+0000) Subject: Fixing the file call in the rfc822.Message replacement example. X-Git-Tag: v3.2a1~1398 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=bb30da9698e50bf33d2ab820fc876c6e9452e33b;p=python Fixing the file call in the rfc822.Message replacement example. --- diff --git a/Doc/includes/email-headers.py b/Doc/includes/email-headers.py index edaac235f3..664c3ff1ca 100644 --- a/Doc/includes/email-headers.py +++ b/Doc/includes/email-headers.py @@ -2,7 +2,7 @@ from email.parser import Parser # If the e-mail headers are in a file, uncomment this line: -#headers = Parser().parse(messagefile) +#headers = Parser().parse(open(messagefile, 'r')) # Or for parsing headers in a string, use: headers = Parser().parsestr('From: \n'