[OSM-dev] "Expect error 417" is back

Frederik Ramm frederik at remote.org
Thu Apr 23 08:55:48 BST 2009


Hi,

Tom Hughes wrote:
> Could you explain what you're talking about exactly? If you're talking 
> about the api then no, it isn't running apache. It's running lighttpd as 
> it has done for the last couple of years.

"The PHP curl library [...] uses a special HTTP 1.1: 100 (Continue) 
Status on POST requests, that have a certain size. Some webservers (like 
lighttpd) do not support this behaviour and return HTTP error codes (417 
in case of lighttpd)."

Experts disagree on whose fault it is (curl's or lighttpd's).

The problem can be fixed by patching lighthttpd (problem is reportedly 
fixed for 1.5 in SVN), or by patching curl, or by manually setting the 
header to nothing from PHP like this:

   curl_setopt($curl_handle, CURLOPT_HTTPHEADER, array('Expect:'));

Bye
Frederik





More information about the dev mailing list