summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEzio Melotti <ezio.melotti@gmail.com>2011-10-18 10:26:49 (GMT)
committerEzio Melotti <ezio.melotti@gmail.com>2011-10-18 10:26:49 (GMT)
commit3de134b1d18ab2e74a4093358fd28333eb101f7a (patch)
tree1d7fb8fc282feb9f8a1a73b126fd0f199f8f7286
parentbb8606dae37b69c06d494f41470975d43385315b (diff)
parent6bfecd1271b305afcbe3f3f68980f89aa44e1910 (diff)
downloadcpython-3de134b1d18ab2e74a4093358fd28333eb101f7a.zip
cpython-3de134b1d18ab2e74a4093358fd28333eb101f7a.tar.gz
cpython-3de134b1d18ab2e74a4093358fd28333eb101f7a.tar.bz2
#12448: merge with 3.2.
-rw-r--r--Lib/smtplib.py1
-rw-r--r--Misc/NEWS3
2 files changed, 4 insertions, 0 deletions
diff --git a/Lib/smtplib.py b/Lib/smtplib.py
index 68fc646..d37b0e2 100644
--- a/Lib/smtplib.py
+++ b/Lib/smtplib.py
@@ -940,6 +940,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 abe2e23..375b945 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -311,6 +311,9 @@ Core and Builtins
Library
-------
+- Issue #12448: smtplib now flushes stdout while running ``python -m smtplib``
+ in order to display the prompt correctly.
+
- Issue #12454: The mailbox module is now using ASCII, instead of the locale
encoding, to read and write MH mailboxes (.mh_sequences files).