cURL / Mailing Lists / curl-users / Single Mail

curl-users

behavior during POST

From: David Byron <DByron_at_everdreamcorp.com>
Date: Mon, 6 Oct 2003 08:41:44 -0700

I'm seeing some behavior I don't expect from curl during an http POST and
was wondering if anyone can clarify this for me. I've read a bit of RFC
2616 but probably not enough to know for sure what's "supposed" to happen.

I invoke curl like this:

$ curl --fail -F File=@<some file> <some url>

From looking at the trace, the server sends back a 100-Continue message, and
curl proceeds to send the file. One of our tests involves stopping the
server after it sends the 100-Continue, so curl doesn't receive any more
data over http. The part that seems odd to me is that curl still has an
exit code of 0.

When we leave the server running normally, it responds with a 200-OK message
after curl sends the entire file.

Is it expected/desirable for curl to return some error if it never gets the
final OK message?

I've only tried this with an IIS server. Not sure what happens with other
servers.

I'm using curl 7.10.7 on Windows. I can send info from the trace if it's
helpful.

Thanks much.

-DB

-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
Received on 2003-10-06