linux-c-programming.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* C/C++ Debugging techniques
       [not found] <20020604071008Z316528-22651+74173@vger.kernel.org>
@ 2002-06-12 12:01 ` Adam Luchjenbroers
  2002-06-12 13:28   ` Elias Athanasopoulos
  2002-06-13  4:04   ` chuckw
  0 siblings, 2 replies; 3+ messages in thread
From: Adam Luchjenbroers @ 2002-06-12 12:01 UTC (permalink / raw)
  To: linux-c-programming

I plan to start doing some debugging and stabilisation work on an open-source 
project. It provides the functionality I'm looking for but is incredibly 
unstable.

So I plan to attempt to fix the code. Before I started I thought I'd ask for 
advice on techniques for debugging code and how to make use of things such as 
core-dumps to find the problem. I hope to learn something from the advice 
people may give me.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: C/C++ Debugging techniques
  2002-06-12 12:01 ` C/C++ Debugging techniques Adam Luchjenbroers
@ 2002-06-12 13:28   ` Elias Athanasopoulos
  2002-06-13  4:04   ` chuckw
  1 sibling, 0 replies; 3+ messages in thread
From: Elias Athanasopoulos @ 2002-06-12 13:28 UTC (permalink / raw)
  To: Adam Luchjenbroers; +Cc: linux-c-programming

On Wed, Jun 12, 2002 at 09:31:47PM +0930, Adam Luchjenbroers wrote:

> So I plan to attempt to fix the code. Before I started I thought I'd ask for 
> advice on techniques for debugging code and how to make use of things such as 
> core-dumps to find the problem. I hope to learn something from the advice 
> people may give me.

Use Electric Fence or memprof to find critical memory corruption errors,
mem leaks, etc. Inspect the core files using gdb to see where the bug
is:

% gdb ./foo ./core
[...]
% where

Elias

-- 
http://gnewtellium.sourceforge.net			MP3 is not a crime.	

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: C/C++ Debugging techniques
  2002-06-12 12:01 ` C/C++ Debugging techniques Adam Luchjenbroers
  2002-06-12 13:28   ` Elias Athanasopoulos
@ 2002-06-13  4:04   ` chuckw
  1 sibling, 0 replies; 3+ messages in thread
From: chuckw @ 2002-06-13  4:04 UTC (permalink / raw)
  To: linux-c-programming

On Wed, Jun 12, 2002 at 09:31:47PM +0930, Adam Luchjenbroers wrote:
> I plan to start doing some debugging and stabilisation work on an open-source 
> project. It provides the functionality I'm looking for but is incredibly 
> unstable.
> 
> So I plan to attempt to fix the code. Before I started I thought I'd ask for 
> advice on techniques for debugging code and how to make use of things such as 
> core-dumps to find the problem. I hope to learn something from the advice 
> people may give me.
> -
> To unsubscribe from this list: send the line "unsubscribe linux-c-programming" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

If you are inexperienced with command line debuggers, there are a few nice
graphical ones.  The one I use is ddd which is a frontend to gdb and a few
other possible debuggers.

Chuck

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2002-06-13  4:04 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20020604071008Z316528-22651+74173@vger.kernel.org>
2002-06-12 12:01 ` C/C++ Debugging techniques Adam Luchjenbroers
2002-06-12 13:28   ` Elias Athanasopoulos
2002-06-13  4:04   ` chuckw

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).