cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: Reg: Expect: option

From: Savitha Perumal <savithap_at_yahoo-inc.com>
Date: Fri, 19 Jun 2009 00:34:13 -0700

Hi

Using POST with HTTP 1.1 implies the use of a "Expect: 100-continue"
which makes curl to split the requests if the POST data is greater than 1K.
I am using set CURLOPT_HTTPHEADER to "Expect:" to stop curl from splitting the data.

headersList = curl_slist_append(headersList, "Expect:");
  curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headersList);

But curl still split the posts.
....

Content-Length: 1405^M
Content-Type: application/x-www-form-urlencoded^M
Expect: 100-continue^M
....

Also, we observed a core drop in the following location.

(gdb) where
#0 0x212e88f4 in strncasecmp () from /usr/lib32/compat/libc.so.4
#1 0x21d7e5ea in curl_strnequal () from /usr/local/lib/libcurl.so.4
#2 0x21d66534 in checkheaders () from /usr/local/lib/libcurl.so.4
#3 0x21d6854c in Curl_http () from /usr/local/lib/libcurl.so.4
#4 0x21d74bba in Curl_do () from /usr/local/lib/libcurl.so.4
#5 0x21d81a84 in multi_runsingle () from /usr/local/lib/libcurl.so.4
#6 0x21d8212e in curl_multi_perform () from /usr/local/lib/libcurl.so.4

Environment : Free BSD4,
Curl : 7.19.4_1

Thanks
Savitha
Received on 2009-06-19