From: Thomas Egerer Date: Thu, 7 Aug 2014 16:05:46 +0000 (+0200) Subject: starter: Don't monitor child if debugger is attached X-Git-Tag: 5.2.1dr1~107 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f51c923f69f921b8888aff7cd3ab29fc6aea6ab8;p=thirdparty%2Fstrongswan.git starter: Don't monitor child if debugger is attached Signed-off-by: Thomas Egerer --- diff --git a/src/starter/invokecharon.c b/src/starter/invokecharon.c index d981f6c17c..d40ab8c283 100644 --- a/src/starter/invokecharon.c +++ b/src/starter/invokecharon.c @@ -201,6 +201,11 @@ int starter_start_charon (starter_config_t *cfg, bool no_fork, bool attach_gdb) default: /* father */ _charon_pid = pid; + if (attach_gdb) + { + /* don't monitor pid file if gdb is attached */ + return 0; + } for (i = 0; i < 500 && _charon_pid; i++) { /* wait for charon for a maximum of 500 x 20 ms = 10 s */