about summary refs log tree commit diff
diff options
context:
space:
mode:
authorChristian Neukirchen <chneukirchen@gmail.com>2015-08-07 11:56:54 +0200
committerChristian Neukirchen <chneukirchen@gmail.com>2015-08-07 11:56:54 +0200
commit0dbd303d2c0d0cc411aa2791c1640452a8f407a9 (patch)
treee6644331c1a1ea24eab35e36a67f0b2496f55f35
parent17c5dbc0f553b04dd0815c3da2a17cf1a0cc4ef3 (diff)
downloadnq-0dbd303d2c0d0cc411aa2791c1640452a8f407a9.tar.gz
nq-0dbd303d2c0d0cc411aa2791c1640452a8f407a9.tar.xz
nq-0dbd303d2c0d0cc411aa2791c1640452a8f407a9.zip
nq: launch job in own process group to simplify killing it all.
-rw-r--r--nq.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/nq.c b/nq.c
index 5c1ac74..bc12132 100644
--- a/nq.c
+++ b/nq.c
@@ -280,6 +280,7 @@ again:
 	close(lockfd);
 
 	setenv("NQJOBID", lockfile+1, 1);
+	setsid();
 	execvp(argv[1], argv+1);
 
 	perror("execvp");