]> granicus.if.org Git - curl/commit
http: fix missing 'Content-Length: 0' while negotiating auth
authorIsaac Boukris <iboukris@gmail.com>
Fri, 3 Feb 2017 12:30:26 +0000 (14:30 +0200)
committerJay Satiro <raysatiro@yahoo.com>
Fri, 17 Feb 2017 07:32:16 +0000 (02:32 -0500)
commit13e3a18b345af1a15b892b0bbedfbbff06e10a39
tree287181977e87aab9d983c6ed118d3d8d86cb146e
parent3cc30e8207b5ab3a9a381c0ff3584d1af8dc54a1
http: fix missing 'Content-Length: 0' while negotiating auth

- While negotiating auth during PUT/POST if a user-specified
  Content-Length header is set send 'Content-Length: 0'.

This is what we do already in HTTPREQ_POST_FORM and what we did in the
HTTPREQ_POST case (regression since afd288b).

Prior to this change no Content-Length header would be sent in such a
case.

Bug: https://curl.haxx.se/mail/lib-2017-02/0006.html
Reported-by: Dominik Hölzl
Closes https://github.com/curl/curl/pull/1242
lib/http.c
tests/data/Makefile.inc
tests/data/test1284 [new file with mode: 0644]
tests/data/test1285 [new file with mode: 0644]