Debugging question

M. Schatzl lists at neuronenwerk.de
Wed Feb 2 15:10:09 PST 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,

what is considered best practice for debugging fork()ed off processes
with gdb? The answer may be fairly obvious to those of you working
with it every other day. But I didn't come across a solution except for
- - insert a loop at the beginning of the child-code
- - when loop is reached, look up PID
- - attach new process
- - release loop flag
I suspect there might be sth. more sophisticated to get along with a
thing like code containing fork()s, which isn't exactly rare. I know
about the follow-fork-mode, but it doesn't seem to work.
Thanks in advance for any help/suggestions.

All the best,
/Markus


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (GNU/Linux)
iD8DBQFCAV2tV/arRO6fNWsRArP+AJ0SuldzZsFAPbfjS1Cekeq1QONLTACfU4nh
V3K1jiswmmj1agvzuFlkJHk=
=H5ig
-----END PGP SIGNATURE-----




More information about the Users mailing list