cURL / Mailing Lists / curl-library / Single Mail

curl-library

CURLINFO_COOKIELIST and curl_easy_getinfo()

From: Patrick <mccpat_at_gmail.com>
Date: Tue, 8 May 2007 15:58:02 -0400

I'm trying to get a list of cookies from a handle using this code in
Windows (using Dev-Cpp and libcurl 7.16.2)

---
struct curl_slist *cookies = NULL;
CURLcode ret = curl_easy_getinfo(handle, CURLINFO_COOKIELIST, &cookies);
---
However, curl_easy_getinfo() always returns a code of 43, which has an
error of "a libcurl function was given a bad argument". The handle is
valid... a few lines previous, it was used in curl_easy_perform(),
which executed with no errors.
If I replace CURLINFO_COOKIELIST with another option such as
CURLINFO_NUM_CONNECTS, and replace the pointer to a curl_slist with a
pointer to a long, no error occurs.
Received on 2007-05-08