# HG changeset patch # User Augie Fackler # Date 2013-09-20 13:16:07 # Node ID 50d721553198cea51c30f53b76d41dc919280097 # Parent 3b82d412e9e8c660ff97e124bbc53e08faaf37cd httpconnection: properly inject ssl_wrap_socket into httpclient (issue4038) This causes httpclient to use the same SSL settings as the rest of Mercurial, and adds an easy extension point for later modifications to our ssl handling. diff --git a/mercurial/httpconnection.py b/mercurial/httpconnection.py --- a/mercurial/httpconnection.py +++ b/mercurial/httpconnection.py @@ -275,14 +275,13 @@ class http2handler(urllib2.HTTPHandler, if '[' in host: host = host[1:-1] - if keyfile: - kwargs['keyfile'] = keyfile - if certfile: - kwargs['certfile'] = certfile + kwargs['keyfile'] = keyfile + kwargs['certfile'] = certfile kwargs.update(sslutil.sslkwargs(self.ui, host)) con = HTTPConnection(host, port, use_ssl=True, + ssl_wrap_socket=sslutil.ssl_wrap_socket, ssl_validator=sslutil.validator(self.ui, host), **kwargs) return con