splitbrain/dokuwiki — pull request #107 by whoopdedo (2012-06-20 22:05:37+00:00)
Title: HTTPClient fix to correctly handle chunked transfer encoding

I found that HTTPClient was doing the wrong thing with chunked transfers. In the process of fixing the bug I cleaned up other parts of the socket handling such as error handling and timeouts.

The reason the problem didn't appear often is because requests were sent as HTTP/1.0 and most servers will only deliver chunked responses to 1.1 clients. With this fixed, would it be a good idea to advertise the client as HTTP/1.1?

I was also thinking about taking advantage of libcurl if it is available.