Closed fyfey closed 8 years ago
The problem is that cURL sends the header "Expect: 100-continue" by default. But curl-client does not support the "Expect-Continue" mechanism. I'll suppress "Expect" header to resolve this bug. And if you need support for "Expect-Continue", please, create a separate issue for it.
Please, try this Client.php
Thanks mekras, I've just deployed the new Client and will let you know how testing goes
This has indeed resolved the problems we were having. Thanks for the quick response!
I would like to add the ability to handle a 100-continue status from the server as I just hit a bug where I would get the following response:
It gets the initial header line and then throws an exception parsing
HTTP/1.1 200 OK
as a header due to the missing colon.I fixed it by setting an empty "Expect" header. Somewhere an "Expect 100-continue" was being added to my request (I wasn't explicitly setting this).
Could we check the initial status line for this status, and then discard the first 2 lines and resume parsing the actual response?