Hello all!
I am sorry my first post here is a question. I hope to contribute during the posting and replies on this thread.
I am stuck for 1 week in a *** stack smashing detected *** bug in my C program running in a i386 desktop with Ubuntu 7.0.4.
I would have pasted the code here but its approx 2000 lines. It has a dozen of functions and a main program. gdb backtrace reports the error ocurred at the instruction that return from the main program, hence, curiously all the outputs from the program are done successfully but the program does not end normally as it abnormally terimnate with this bug (!!).
I tryed to detect the line in the source code where I could be smashing the stack with valgrind, but I arrived to the conclusion that it canīt help me to debug my current stack smashing error (Reference: Go to the page below on wikipedia, and make a "search in this page" for the "stack smashing"
http://en.wikipedia.org/wiki/Valgrind
I am currently carefully checking each line of code, one by one, trying to find out the buggy statement. Meanwhile I would appreciate if someone could:
1- Point out any tool that may help me to pinpoint where (I mean, in which statement) I am doing this stack smashing?
2- Give me some clues that could help me speeding up the buggy statement identification in the code.