]> granicus.if.org Git - python/commit
#17443: Fix buffering in IMAP4_stream.
authorR David Murray <rdmurray@bitdance.com>
Tue, 19 Mar 2013 17:52:33 +0000 (13:52 -0400)
committerR David Murray <rdmurray@bitdance.com>
Tue, 19 Mar 2013 17:52:33 +0000 (13:52 -0400)
commitfcb6d6a3b3bfba67927ced18dd648ba889e14f4c
tree2fd07ed3bc58201cfb53ad8046c83a80bdec4bd4
parentae4ef4d2ff2d49628516294837249493f43a5047
#17443: Fix buffering in IMAP4_stream.

In Python2 Popen uses *FILE objects, which wind up buffering even though
subprocess defaults to no buffering.  In Python3, subprocess streams really
are unbuffered by default, but the imaplib code assumes read is buffered.  This
patch uses the default buffer size from the io module to get buffered streams
from Popen.

Much debugging work and patch by Diane Trout.

The imap protocol is too complicated to write a test for this simple
change with our current level of test infrastructure.
Lib/imaplib.py
Misc/ACKS
Misc/NEWS