Archived

This topic is now archived and is closed to further replies.

Seg fault hunting

This topic is 5312 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

right, first just a clarification for me, a seg fault is my program doing something funky with memory, yes? assuming that is true, what is the best way to hunt one down. I have a fairly good idea where the problem occurs, and when, but I have no idea what it is thats doing it... So Im looking for some general ideas here, so that i can look at this function and see where its breaking stuff... Cheers for any help...

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
There''s this great invention, known as A DEBUGGER.

It will let you STOP your program at determined places using BREAK POINTS.

There, you can INVESTIGATE VALUES OF VARIABLES.

Also, if your program crashes, the debugger will usually give you a STACK TRACE showing the CALL CHAIN leading up to the crash, and let you again INSPECT VARIABLES.


I know this sounds like brain surgery or something, but trust me, when you learn how to use one, you don''t want to go back.

Share this post


Link to post
Share on other sites