Mail Archives: djgpp/1996/08/12/19:17:01
Ok, I am STILL writing this window stuff, and using a lot of doubly linked
lists...
The problem: When I run the program normally, it dies with a seg fault...I
have found the problem line using the traceback eip, and its:
x = temp->next->x;
in the subroutine which looks something like:
while (temp->next != NULL)
{
...
x = temp->next->x;
...
}
I KNOW that the original structures pointer to next is originally assigned
to NULL when it is added onto the end of a list (this is the only time
it crashes), but upon execution of the program from the command line (win.exe)
it crashes. Using printf of the temp->next value, I get some weird negative
number like -24.
Anyway, I can't seem to debug it, because when I run the program under
fsdb and single step, run etc the program, it runs fine!!!
WHY?
Leathal.
- Raw text -