~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

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

  • Committer: Vincent Ladeuil
  • Date: 2010-10-26 08:08:23 UTC
  • mfrom: (5514.1.1 665100-content-type)
  • mto: This revision was merged to the branch mainline in revision 5516.
  • Revision ID: v.ladeuil+lp@free.fr-20101026080823-3wggo03b7cpn9908
Correctly set the Content-Type header when POSTing http requests

Show diffs side-by-side

added added

removed removed

Lines of Context:
268
268
        # We override the Expect: header so that pycurl will send the POST
269
269
        # body immediately.
270
270
        try:
271
 
            self._curl_perform(curl, header, ['Expect: '])
 
271
            self._curl_perform(curl, header,
 
272
                               ['Expect: ',
 
273
                                'Content-Type: application/octet-stream'])
272
274
        except pycurl.error, e:
273
275
            if e[0] == CURLE_SEND_ERROR:
274
276
                # When talking to an HTTP/1.0 server, getting a 400+ error code