Re: Squid-ICAP problem (bug?)

From: Tsantilas Christos <chtsanti@dont-contact.us>
Date: Sun, 03 Dec 2006 18:27:43 +0200

Hi Christophe,
 Maybe I was not clear on my last mail. Sorry.

Christophe Boyanique wrote:
>
>
> in icapReqModReadHttpBody function replacing the test
>
> if (icap->reqmod.http_entity.bytes_read >= icap->request->content_length)
>
> by
>
> if (icap->chunk_size < 0)

OK this is needed.
But in the same function replace the test:
   if (icap->reqmod.http_entity.callback &&
icap->reqmod.http_entity.buf.size) {
      icapReqModPassHttpBody(icap,
      icap->reqmod.http_entity.callback_buf,
      icap->reqmod.http_entity.callback_bufsize,

with:
  if (icap->reqmod.http_entity.callback) {
        icapReqModPassHttpBody(icap,
            icap->reqmod.http_entity.callback_buf,
            icap->reqmod.http_entity.callback_bufsize,

Did you try it?

>
> which correct the initial problem ie not reading the 0\r\n marking thee
> end of the chunk.
>
> The new problem is that squid correctly reads the end of the chunk but
> dies immediatly.
>
I think with the previous change the problem must be solved.

> .........................
> 2006/12/01 18:18:19| icap_reqmod.c:903 http_entity.callback_bufsize = 8192
> 2006/12/01 18:18:19| icap_reqmod.c:917 icapReqModReadHttpBody: end of
> function
>
> and we exit the icapReqModReadHttpBody function without calling
> icapReqModPassHttpBody because http_entity.buf.size is 0.
>
 With the previous change this function must called here.....
Did you make this change? Are you still seeing segfaults?

In my tests I am not seeing any problem any more. But maybe I am losing
something....

Regards,
       Christos
Received on Sun Dec 03 2006 - 09:28:59 MST

This archive was generated by hypermail pre-2.1.9 : Sat Dec 30 2006 - 12:00:04 MST