[OpenSER-Devel] Debugging modules code

Henning Westerholt henning.westerholt at 1und1.de
Fri Mar 14 11:35:50 CET 2008


On Sunday 09 March 2008, Ivan Genov wrote:
> How can I debug a module I am developing? I would like if I can debug
> within KDevelop, but any other way as far as I can put breakpoints and
> examine variables is good too. Debugging the core would be helpful too.
>
> If there is documentation about that just point me to it and I will be glad
> to read it.

Hi Ivan,

sure, you could use KDevelop, or any other gdb frontend to step through your 
code.

You get a quite detailed insight into the working of the core if you enable 
the debugging (increase loglevel) in your config. You could also provide DBG 
statements in your module, that report about certain conditions and internal 
states of the logic.

I also add (temporary) more logging output to the module code, in the 
old "debugging with printf" way, perhaps change the log level of statements, 
to be able to observe them even with normal logging setting.

If you want to observe the memory manager in more detail, then you should 
compile with memory debugging activated (see Makefile.defs). This way more 
check are done during runtime, and on shutdown extensive statistics are 
printed.

Cheers,

Henning



More information about the Devel mailing list