Re: gdb (linux) "print" command clears memory corruption - so how
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Unix and Linux reviews > Free Unix support > Unix Programming > Re: gdb (linux) "print" command clears memory corruption - so how




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Re: gdb (linux) "print" command clears memory corruption - so how  
examnotes


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
01-23-04 10:02 PM

kreuiter@netscape.net (Gavin Kreuiter) writes:
quote:
> I am looking for some advice on how to debug a program when the > debugger "print" command actually clears the corruption. This is not > the usual non-initialised memory problem, because the program aborts > with a SIGBUS inside the debugger as well. But when I use the print > command inside the debugger, the program completes normally.
You have a Schrödinger bug, i.e. one that changes when you observe it. Since you are running Linux, I'd suggest you try out valgrind, http://valgrind.kde.org/. It's a debugger that will usually catch most kinds of memory related bugs.
quote:
> (I orignally posted this to comp.lang.c, but suspect that I might have > chosen the wrong newsgroup. Perhaps someone can also advise me how I > determine which group to post a query to; is there a FAQ on choosing > newsgroups?)
Browse the list of groups and find those that look appropriate to you. Then fetch the FAQ for those groups, and see if it looks right. It might even answer your question. -- Måns Rullgård mru@kth.se




[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 01:19 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register