cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: CURLOPT_COOKIEJAR not working from Java?!?

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 13 Mar 2002 10:39:31 +0100 (MET)

On Wed, 13 Mar 2002, Serge Kruppa wrote:

> I'm trying to get a session ID cookie stored in a file by using
> CURLOPT_COOKIEJAR (code 10082) from a Java program that invokes libcurl
> (see below).

code 10082? ;-) You should probably re-run your define2java.pl script to get
a proper name for that option.

> I can see from the verbose output that the cookie is accepted (i.e. I see
> "Cookie: sesessionid=5JS4NP3MRCDGMIIDBLQU2UA" on the console) but no
> cookie.txt file gets created. What am I doing wrong?

The cookie jar file is created when you call curl_easy_cleanup() and not
until then.

Before that happens, the cookies are kept in memory.

-- 
    Daniel Stenberg -- curl groks URLs -- http://curl.haxx.se/
Received on 2002-03-13