|
From: Steven J. B. <ba...@ma...> - 2005-04-18 16:21:19
|
A program we use, makeped, is segfaulting, valgrind says: ==16881== TRANSLATE: 0x1B98BF90 redirected to 0x1B9039E0 ==16881== Use of uninitialised value of size 4 ==16881== at 0x804B64F: main (makeped.c:1758) trc=31 jump to 0xB00673BA from 0x804B64B ==16881== ==16881== Jump to the invalid address stated on the next line ==16881== at 0xB00673BA: vgSkinInternal_free (vg_toolint.c:538) ==16881== Address 0xB00673BA is not stack'd, malloc'd or (recently) free'd ==16881== ==16881== Invalid read of size 4 ==16881== at 0xB00673CD: vgSkinInternal_free (vg_toolint.c:539) ==16881== by 0x1BA5A1B7: ??? ==16881== Address 0xB009E3E4 is not stack'd, malloc'd or (recently) free'd ==16881== ==16881== Process terminating with default action of signal 11 (SIGSEGV) ==16881== GPF (Pointer out of bounds?) ==16881== at 0xB00673CD: vgSkinInternal_free (vg_toolint.c:539) ==16881== by 0x1BA5A1B7: ??? trc=0 jump to 0xB00673CD from 0xB00673BA There is no code at line 1758 of makeped and the debugger isn't telling me much. Anyone have any ideas on how to proceed? Thanks, Steve |
|
From: Dennis L. <pla...@in...> - 2005-04-18 19:33:27
|
At 17:50 18.04.2005, Steven J. Backus wrote: > A program we use, makeped, is segfaulting, valgrind says: > >==16881== TRANSLATE: 0x1B98BF90 redirected to 0x1B9039E0 >==16881== Use of uninitialised value of size 4 >==16881== at 0x804B64F: main (makeped.c:1758) >trc=31 jump to 0xB00673BA from 0x804B64B >==16881== >==16881== Jump to the invalid address stated on the next line >==16881== at 0xB00673BA: vgSkinInternal_free (vg_toolint.c:538) >==16881== Address 0xB00673BA is not stack'd, malloc'd or (recently) free'd >==16881== >==16881== Invalid read of size 4 >==16881== at 0xB00673CD: vgSkinInternal_free (vg_toolint.c:539) >==16881== by 0x1BA5A1B7: ??? >==16881== Address 0xB009E3E4 is not stack'd, malloc'd or (recently) free'd >==16881== >==16881== Process terminating with default action of signal 11 (SIGSEGV) >==16881== GPF (Pointer out of bounds?) >==16881== at 0xB00673CD: vgSkinInternal_free (vg_toolint.c:539) >==16881== by 0x1BA5A1B7: ??? >trc=0 jump to 0xB00673CD from 0xB00673BA > >There is no code at line 1758 of makeped and the debugger isn't >telling me much. Anyone have any ideas on how to proceed? What is your valgrind version, linux version, compiler used etc. ? Is the line mentioned the last line in main() ? It looks to me like it tries to call some virtual destructor in an object on the stack where the virtual pointer wasnt properly initialized (happened to me once, was a compiler bug there) ? Or maybe the objects that are destroyed (assuming you are using C++, or what language do you use ?) at main() return do something weird ? Is this the full stack trace ? If not, try with --num-callers and a high value. Try to figure out in what object the uninitialized value is (if valgrind doesnt tell you, try attaching with gdb or do printf debugging and print pointers) Well, thats what I would look for, open to other ideas too... greets Dennis Carpe quod tibi datum est |