Re: squid-1.2.beta5 bugs, patches

From: Michael O'Reilly <michael@dont-contact.us>
Date: 08 Nov 1997 13:24:01 +0800

David Luyer <luyer@ucs.uwa.edu.au> writes:
> Now it compiles. Then I defined STORE_KEY_SHA and USE_ASYNC_IO.
> There's a lot in aiops.h which is defined to return something but
> returns nothing, plus an unused variable laying around, but it still
> compiled everything; however I had to manually edit -lpthread into
> src/Makefile, even though I'd re-run configure.

You can actually do this via configure...

CFLAGS='-DUSE_ASYNC_IO -DSTORE_KEY_SHA' LDFLAGS=-lpthread ./configure

> In src/disk.c
> 381d380
> < fde *F = &fd_table[fd];
> 382a382
> > fde *F = &fd_table[fd];
>
> (F isn't used if USE_ASYNC_IO is set)

gcc should kill it anyway (dead code elimination)
 
[ .. ]
> Now it just segfaults and dies without a core dump (and yes, coredumpsize is
> unlimited). So I undefined ASYNC_IO and SHA cache keys. That got squid -z
> to work. I put back the SHA cache keys (the reason I was looking at this
> version:). Well, that now worked, and that's enough for today :)

Note that you can run it under gdb, and it'll give much more sensible
results..

        gdb
        handle SIGUSR1 nostop noprint # because threads uses USR1
        handle SIGPIPE nostop noprint
        run

also notes that you'll need to comment out all references to SIGUSR1
in main.c ditto USR2. (USR1 and 2 are used for inter-thread signalling
by linuxthreads-0.6)

Michael.
Received on Tue Jul 29 2003 - 13:15:44 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:11:29 MST