cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Bug 2351645

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 3 Dec 2008 20:10:30 +0100 (CET)

On Wed, 3 Dec 2008, Igor Novoseltsev wrote:

> I didn't get response to my last update, quoted below.
>
> Did you see it?
>
> Do you think it is wrong?

> Date: 2008-12-03 10:33
> Sender: ketamin <https://sourceforge.net/users/ketamin/>
> The patch works good!
> Thank you very much!
>
> Although I have one doubt.
> In ligth of your erlier remark regarding readchannel_inuse I think we
> should use
>
> if(Curl_removeHandleFromPipeline(data, conn->XXX_pipe) &&
> conn->XXXchannel_inuse && conn->XXX_pipe->size > 0)
> conn->XXXchannel_inuse = FALSE;
>
> instead of
>
> if(Curl_removeHandleFromPipeline(data, conn->XXX_pipe) &&
> conn->XXXchannel_inuse)
> conn->XXXchannel_inuse = FALSE;

Yes I saw it and yes I think it's unnecessary.

I tried to clarify the meaning of the XXXchannel_inuse fields in the code
just a few days ago:

they're just flags that mean that the "channel" is in use and nobody else can
take it. So when we remove the handle at the head, the channel gets available
and the _inuse field can safely be set to FALSE and the next handle in line
would later become head and "take" the channel and set _inuse to TRUE again.

-- 
  / daniel.haxx.se
Received on 2008-12-03