[New-bugs-announce] [issue4492] httplib code thinks it closes connection, but does not
John J Lee
report at bugs.python.org
Tue Dec 2 19:15:19 CET 2008
New submission from John J Lee <jjlee at users.sourceforge.net>:
The fix for #900744 tried to close the connection when a bad chunk
length was received. The comment inserted with that fix "close the
connection as protocol synchronisation is probably lost" is incorrect:
self.close() in _read_chunked does not close the connection. You have
to call HTTPConnection.close() to close the connection.
* The comment is incorrect, and should be removed or fixed. I guess
the self.close() should stay.
* It's probably a bug that it doesn't result in the connection being
closed. I guess a fix for that would be for the HTTPResponse to set
some state on itself that HTTPConnection can query so that
HTTPConnection can close itself the next time somebody tries to do
something with the connection.
components: Library (Lib)
title: httplib code thinks it closes connection, but does not
versions: Python 2.6, Python 2.7, Python 3.0
Python tracker <report at bugs.python.org>
More information about the New-bugs-announce