curl-users
Re: Problem with libcURL resuming transfer after doing a directorylisting...
Date: Wed, 27 Apr 2005 17:09:31 -0700
On Wed, Apr 27, 2005 at 07:13:42PM -0400, David Fix wrote:
> Alright, here's the EXACT code (with a working URL and everything) that I
> used to make this happen...
> If you try this, you'll see that it hangs when it goes to retrieve the file
> after getting the directory listing.
> Let me know if you have any ideas, please! :)
You're reusing the curl handle from within the write callback. When the
callback returns, curl tries to continue with the transfer that caused the
write call, but the handle is then in a completely different state. No wonder
this doesn't work.
If you want to do another transfer within the callback, you'll need to create
a new curl handle. But a better way is probably to set a flag within the
callback and do the second transfer in your main code after the first
curl_easy_perform() call returns.
>>> Dan
-- http://www.MoveAnnouncer.com The web change of address service Let webmasters know that your web site has movedReceived on 2005-04-28