1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-16 23:42:43 +01:00
This commit is contained in:
Eelco Dolstra 2023-03-20 18:06:08 +01:00
parent 16db8dc96f
commit 515662ad70
4 changed files with 7 additions and 8 deletions

View file

@ -35,7 +35,10 @@ HookInstance::HookInstance()
/* Fork the hook. */
pid = startProcess([&]() {
commonChildInit(fromHook.writeSide.get());
if (dup2(fromHook.writeSide.get(), STDERR_FILENO) == -1)
throw SysError("cannot pipe standard error into log file");
commonChildInit();
if (chdir("/") == -1) throw SysError("changing into /");

View file

@ -1656,7 +1656,7 @@ void LocalDerivationGoal::runChild()
try { /* child */
commonChildInit(-1);
commonChildInit();
try {
setupSeccomp();