cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: libcurl loop

From: Tyler Brock <tyler.brock_at_gmail.com>
Date: Wed, 22 Sep 2010 10:57:39 -0400

Than you Dan and Mehmet.

Mehmet, I will take your advice and move those out of the loop.

Dan, I think you are right and that this is the root of the issue. How do I
ensure the cookies are new on each run and I'm not caching the old ones?

Please let me know, thanks!

-Tyler

Tyler J. Brock

On Wed, Sep 22, 2010 at 2:40 AM, Dan Fandrich <dan_at_coneharvesters.com>wrote:

> On Tue, Sep 21, 2010 at 10:10:20PM -0400, Tyler Brock wrote:
> > I'm trying to use curl to login and retrieve information from a couple of
> web
> > pages in a loop using a two step process.
> >
> > The first curl logs in to the page.
> > The second curl takes the same curl handle and gets another page which is
> > stored in memory to later be parsed by another function that I wrote.
> >
> > The problem I'm having is that individually each run of the loop works
> when
> > isolated, but when you do two or more in a row it fails to
> login successfully.
>
> Could it be related to stale cookies being left over from previous runs
> of the loop?
>
> >>> Dan
> -------------------------------------------------------------------
> List admin: http://cool.haxx.se/list/listinfo/curl-library
> Etiquette: http://curl.haxx.se/mail/etiquette.html
>

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2010-09-22