mercurial/httpconnection.py
branchstable
changeset 26813 b66e3ca0b90c
parent 26347 e9a35411bbbc
child 27521 b1adf32b0605
equal deleted inserted replaced
26535:d3712209921d 26813:b66e3ca0b90c
   105     def close(self):
   105     def close(self):
   106         pass
   106         pass
   107 
   107 
   108 class HTTPConnection(httpclient.HTTPConnection):
   108 class HTTPConnection(httpclient.HTTPConnection):
   109     response_class = HTTPResponse
   109     response_class = HTTPResponse
   110     def request(self, method, uri, body=None, headers={}):
   110     def request(self, method, uri, body=None, headers=None):
       
   111         if headers is None:
       
   112             headers = {}
   111         if isinstance(body, httpsendfile):
   113         if isinstance(body, httpsendfile):
   112             body.seek(0)
   114             body.seek(0)
   113         httpclient.HTTPConnection.request(self, method, uri, body=body,
   115         httpclient.HTTPConnection.request(self, method, uri, body=body,
   114                                           headers=headers)
   116                                           headers=headers)
   115 
   117