Re: need way to debug tool called by popen--at startup
Re: need way to debug tool called by popen--at startup
- Subject: Re: need way to debug tool called by popen--at startup
- From: Greg Guerin <email@hidden>
- Date: Thu, 30 Apr 2009 10:31:40 -0700
Jonas Maebe wrote:
Alternatively, you can add a sleep(10) or however long you need at
the beginning of the command line tool, so that you do get enough
time to attach gdb manually.
The functions sigsuspend() and pause() may also be useful. There are
specific signals that always and only pause/continue a process
(SIGSTOP, SIGCONT).
Another useful thing is to condition the call to sleep(), pause(),
etc. on the presence of a specific environment variable value. Then
to force the initial pause, you set the env-var, but normally you
don't. This allows one to enable and disable the pause without
having to recompile.
-- GG
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden