Menu

problem with using the debugger of Dev-c++

saisai
2007-11-02
2012-09-26
  • saisai

    saisai - 2007-11-02

    hi all,

    I have a question about debugging.
    I always use the debugger to find out the line which caused segmentation fault.
    it will highlight the line that caused the segfault and i can backtrace the line
    But today when i use it to debug, when th debugger stop the program.
    No line is highlighted and I can't find the backtrace information.
    I wonder this problem is caused by my setting or other thing else.

    I have already enable the debug information in the linker option.

    Thanks so much

     
    • Anonymous

      Anonymous - 2007-11-02

      It is likely that you have corrupted the stack and therefore the back-trace. You'll have to use an alternative strategy - stepping the code until the seg fault, then restarting and executing until just before the fault, then look at the data and see what you have done. A buffer overrun of a local array for example will corrupt the stack.

      One way of finding the error is to observe the back trace (call stack) while stepping the code. If the call stack suddenly becomes unintelligible, you have just stomped on it.

      Clifford

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.