From 8e9fd57ef9aa47214418212916e54c5644721335 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 18 May 2004 09:45:18 +0000 Subject: [PATCH] * setpgrp() is not POSIX (and on Mac OS X it's different than on Linux), so use setpgid(). --- src/libstore/normalise.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libstore/normalise.cc b/src/libstore/normalise.cc index 341234d66..7498ef20f 100644 --- a/src/libstore/normalise.cc +++ b/src/libstore/normalise.cc @@ -806,7 +806,7 @@ void Normaliser::initChild(Goal & goal) { /* Put the child in a separate process group so that it doesn't receive terminal signals. */ - if (setpgrp() == -1) + if (setpgid(0, 0) == -1) throw SysError(format("setting process group")); if (chdir(goal.tmpDir.c_str()) == -1)