cURL / Mailing Lists / curl-library / Single Mail



From: Daniel Stenberg <>
Date: Tue, 16 Dec 2003 13:25:34 +0100 (CET)

On Fri, 12 Dec 2003, DOMINICK C MEGLIO wrote:

> > libcurl doesn't help you all the way with this, you need to fetch the
> > HTTP response code and if you got a 304 back, it means that the
> > timecondition didn't evaluate true.
> Ok, that doesn't sound too bad. Am I correct in assuming all that means I
> must do is something like:
> curl_easy_perform(curl);
> curl_easy_getinfo(curl, CURLINFO_RESPONSE_CODE, code);
> if (code == 304)
> do_load_from_cache();
> Meaning CURLINFO_RESPONSE_CODE will contain the 304 if it did not meet my
> time condition?

Yeps. That should work.

    Daniel Stenberg -- --
   [[ Do not send mails to this email address. They won't reach me. ]]
This email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now!
Received on 2003-12-16