Hi, Here is a patch for httplib. I added a timeout value for httplib.HTTPConnection, please check. (diff - CVS 1.94) Zhang Yue 2004-12-14 Index: httplib.py =================================================================== RCS file: /cvsroot/python/python/dist/src/Lib/httplib.py,v retrieving revision 1.94 diff -r1.94 httplib.py 575c575 < def __init__(self, host, port=None, strict=None): ---
def __init__(self, host, port=None, strict=None, timeout=None):
580a581
self.timeout = timeout
613a615,616
if self.timeout: self.sock.settimeout(self.timeout)
ZhangYue张岳 wrote:
Hi,
Here is a patch for httplib. I added a timeout value for httplib.HTTPConnection, please check.
Thanks for the patch, but this is the wrong place for it. Please create a new patch item on SourceForge at http://sourceforge.net/patch/?group_id=5470 . -Brett
Brett C. wrote:
Here is a patch for httplib. I added a timeout value for httplib.HTTPConnection, please check.
Thanks for the patch, but this is the wrong place for it. Please create a new patch item on SourceForge at http://sourceforge.net/patch/?group_id=5470 .
In addition, also avoid using plain diffs - use context or unified diffs instead. Regards, Martin
participants (3)
-
"Martin v. Löwis" -
Brett C. -
ZhangYue张岳