]> granicus.if.org Git - python/commit
merging / reimplementing r68532 from the trunk to Py3k
authorKristján Valur Jónsson <kristjan@ccpgames.com>
Mon, 2 Feb 2009 16:04:04 +0000 (16:04 +0000)
committerKristján Valur Jónsson <kristjan@ccpgames.com>
Mon, 2 Feb 2009 16:04:04 +0000 (16:04 +0000)
commit7e11b3f52247f0a0fd8be8879873a74d4ec02b38
tree578dba804293c292fb033364d9df748f5101f612
parentbc186a87ccd09a62339492cfca794841cab07087
merging / reimplementing r68532 from the trunk to Py3k

Enable buffering for HTTPResponse's fp.  read() behaves identically for buffered and non-buffered IO.  read(n) also won't block if n bytes are availble on the socket.  There is therefore no reason not to use buffering.  The reason 2.x disables buffering by default, that some clients may be accessing the underlying socket directly and so bypass the buffering buffer, doesn't apply in 3.x with its redesigned IO library.
See issue 4448 and issue 4879
Lib/http/client.py
Lib/xmlrpc/client.py