--- a/mercurial/keepalive.py Sun Feb 03 21:03:46 2008 -0200
+++ b/mercurial/keepalive.py Sun Feb 03 21:03:46 2008 -0200
@@ -175,7 +175,7 @@
else:
return dict(self._hostmap)
-class HTTPHandler(urllib2.HTTPHandler):
+class KeepAliveHandler:
def __init__(self):
self._cm = ConnectionManager()
@@ -314,6 +314,9 @@
except socket.error, err: # XXX what error?
raise urllib2.URLError(err)
+class HTTPHandler(KeepAliveHandler, urllib2.HTTPHandler):
+ pass
+
class HTTPResponse(httplib.HTTPResponse):
# we need to subclass HTTPResponse in order to
# 1) add readline() and readlines() methods