cURL / Mailing Lists / curl-library / Single Mail


Re: Performance of POST method

From: Daniel Stenberg <>
Date: Sun, 2 Dec 2001 14:31:49 +0100 (MET)

On Sat, 1 Dec 2001, Hanno L. Kranzhoff wrote:

> Pedro, I faced the same problem as you did.

Uh, where did the mail you replied to come from?

> The solution for me was to disable the "Expect: 100-continue"
> header with
> ---
> m_headerlist = curl_slist_append(m_headerlist, "Expect:");
> ---

> Now there's no delay between the header and the data-part anymore.
> Comments in the sourcecode state that "Expect: 100-continue" is intended
> to speedup posts, but at least in my case it did the exact opposite.

The "Expect: 100-continue" is meant to speedup detection of unwilling
receivers. It hardly speedups normal (accepted) posts.

Your dealing with this is perfect, as it prevents curl from sending that
header and then it won't wait for any Expect reply and thus perform faster.
As long as the POST is accepted.

If the POST isn't accepted, it'll take much longer and you'll have the whole
POST contents transfered before you can get the error code from the server.

    Daniel Stenberg -- curl groks URLs --
Received on 2001-12-02