curl-library
Re: [Update] Re: [hiper] hipev.c ++ ;-)
Date: Tue, 22 Aug 2006 23:50:28 +0200 (CEST)
On Tue, 22 Aug 2006, Alexander Lazic wrote:
> the current output show us that the socks callback was called *after*:
>
> --- in multi_runsingle()
> CURLM_STATE_DO, /* start send off the request (part 1) */
> ---
>
> how about to call the callback *before* the CURLM_STATE_DO?!
I don't understand neither your conclusion nor your question:
1 - CURLM_STATE_DO is a state in the multi handle state machine
2 - multi_runsingle() is internally called to deal with everything
multi-interface and _after_ that function returns, the checks are made
for the socket states etc and the socket_callback is called for the
sockets that have changed state.
It is not possible to call the callback until the change is made, so it MUST
be after multi_runsingle(). But why bother? This should not be a problem. If
it is, that's a bug.
> You can get both outputs (ok,nok) with some printstatments in libcurl from:
BTW, I'm not sure its relevant but a microsecond is one million during one
second, while your app sets the tv_usec to something larger than so.
> http://none.at/ok.run.txt
> http://none.at/nok.run.txt
They are quite hard to read and draw any conclusions from.
Isn't the problem that eventcallback and timercallback are the only functions
that count down number of alive connections, update the timeout etc, so if
none of them are called then those actions won't be performed.
If none of those callbacks are ever called, it would mean that all
transfers should be completed by the time event_dispatch(); is called in your
program? ... And really, it should probably make sure that running_handles is
non-zero before getting called.
-- Commercial curl and libcurl Technical Support: http://haxx.se/curl.htmlReceived on 2006-08-22