~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/transport/http/_urllib.py

  • Committer: John Arbash Meinel
  • Date: 2011-05-11 11:35:28 UTC
  • mto: This revision was merged to the branch mainline in revision 5851.
  • Revision ID: john@arbash-meinel.com-20110511113528-qepibuwxicjrbb2h
Break compatibility with python <2.6.

This includes auditing the code for places where we were doing
explicit 'sys.version' checks and removing them as appropriate.

Show diffs side-by-side

added added

removed removed

Lines of Context:
138
138
        abspath = self._remote_path('.bzr/smart')
139
139
        # We include 403 in accepted_errors so that send_http_smart_request can
140
140
        # handle a 403.  Otherwise a 403 causes an unhandled TransportError.
141
 
        response = self._perform(Request('POST', abspath, body_bytes,
142
 
                                         accepted_errors=[200, 403]))
 
141
        response = self._perform(
 
142
            Request('POST', abspath, body_bytes,
 
143
                    {'Content-Type': 'application/octet-stream'},
 
144
                    accepted_errors=[200, 403]))
143
145
        code = response.code
144
146
        data = handle_response(abspath, code, response.info(), response)
145
147
        return code, data