From: Ian Jackson Date: Sat, 6 Jan 2018 13:53:30 +0000 (+0000) Subject: DEBUGGING PATCH FROM NIIBE (2) X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ian/git?a=commitdiff_plain;h=794f5320c7252d2f8e0114beeb3c3947b538c8c9;p=gnupg2.git DEBUGGING PATCH FROM NIIBE (2) --- diff --git a/common/exechelp-posix.c b/common/exechelp-posix.c index 7237993..3300425 100644 --- a/common/exechelp-posix.c +++ b/common/exechelp-posix.c @@ -850,17 +850,7 @@ gnupg_spawn_process_detached (const char *pgmname, const char *argv[], } if (!pid) { - pid_t pid2; - gcry_control (GCRYCTL_TERM_SECMEM); - if (setsid() == -1 || chdir ("/")) - _exit (1); - - pid2 = fork (); /* Double fork to let init take over the new child. */ - if (pid2 == (pid_t)(-1)) - _exit (1); - if (pid2) - _exit (0); /* Let the parent exit immediately. */ if (envp) for (i=0; envp[i]; i++)