I've run in the weirdest error.
Situation: C program reads data from mySQL database,
nothing fancy, except in this particular case program
dumps core on mysql_close(). I compiled with Electric Fence
and ran via gdb. Below is the output:
........
Program received signal SIGSEGV, Segmentation fault.
0x8058d50 in close ()
(gdb) backtrace
#0 0x8058d50 in close ()
#1 0x804dffc in mysql_close ()
#2 0x804a6b0 in print_template (template=0x805659a "quotes2.htm")
at print_template.c:79
#3 0x804b76a in main (argc=1, argv=0xbffffd74) at main_quote.c:140
#4 0x4004bcb3 in __libc_start_main (main=0x804b4c0 <main>, argc=1,
argv=0xbffffd74, init=0x80491e8 <_init>, fini=0x8053a3c <_fini>,
rtld_fini=0x4000a350 <_dl_fini>, stack_end=0xbffffd6c)
at ../sysdeps/generic/libc-start.c:78
(gdb)
System data:
Red Hat Linux release 6.0 (Hedwig)
Kernel 2.2.5-15smp on an i686
MySQL ver. 3.22.25
I have quite a few other programs running on the same system, never
had anything remotely simialr to that, although, admittedly I'm no
Linux expert.
Any and all ideas will be really appreciated.
Thanks in advance.
A.Heiphetz