From: Ezio Melotti Date: Tue, 18 Oct 2011 10:20:07 +0000 (+0300) Subject: #12448: smtplib now flushes stdout while running ``python -m smtplib`` X-Git-Tag: v3.2.3rc1~496 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6bfecd1271b305afcbe3f3f68980f89aa44e1910;p=thirdparty%2FPython%2Fcpython.git #12448: smtplib now flushes stdout while running ``python -m smtplib`` in order to display the prompt correctly. Patch by Petri Lehtinen. --- diff --git a/Lib/smtplib.py b/Lib/smtplib.py index 13c56e196f8b..fbef96e691fa 100644 --- a/Lib/smtplib.py +++ b/Lib/smtplib.py @@ -912,6 +912,7 @@ if __name__ == '__main__': def prompt(prompt): sys.stdout.write(prompt + ": ") + sys.stdout.flush() return sys.stdin.readline().strip() fromaddr = prompt("From") diff --git a/Misc/NEWS b/Misc/NEWS index fbba9b1626ff..d610ff45f219 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -47,6 +47,9 @@ Core and Builtins Library ------- +- Issue #12448: smtplib now flushes stdout while running ``python -m smtplib`` + in order to display the prompt correctly. + - Issue #13194: zlib.compressobj().copy() and zlib.decompressobj().copy() are now available on Windows.