On Feb 13 04:01, Andrew Klosterman wrote:
> I threw in a pthread mutex around the code making the database connections
> for each of my threads. The problem is still there ("corrupted
> double-linked list").
> ...
> Program received signal SIGILL, Illegal instruction.
> [Switching to Thread 16384 (LWP 24753)]
> 0x401c3851 in kill () from /lib/libc.so.6
> (gdb) bt
> #0 0x401c3851 in kill () from /lib/libc.so.6
> #1 0x40139dd5 in EF_Abort () from /usr/lib/libefence.so.0
> #2 0x40139823 in memalign () from /usr/lib/libefence.so.0
> #3 0x401399ad in malloc () from /usr/lib/libefence.so.0
> #4 0x40139a10 in calloc () from /usr/lib/libefence.so.0
> #5 0x404a182f in krb5_set_default_tgs_ktypes () from /usr/lib/libkrb5.so.3
> #6 0x402c8b3f in ?? () from /usr/lib/libpq.so.4
> #7 0x402ded88 in ?? () from /usr/lib/libpq.so.4
> #8 0x00000000 in ?? ()
I met with some other thread-safety issues caused by libc used in
Debian repos. For instance, getpwuid_r() is broken in Debian's
current stable libc package and this causes a similar memory leak
in the libpq code.
IMHO, testing code with a newer libc version can be the solution.
Otherwise, for an exact answer - as Tom said - we need libpq symbols
in the backtrace.
Regards.