From 4f11cf45dc106a36ac3e02947eddba9ba1902ad8 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 5 Apr 2017 11:01:57 +0200 Subject: [PATCH] Fix build cancellation We nowadays ignore SIGINT, so the sshd child process inherited this and ignored SIGINT as well. --- src/hydra-queue-runner/build-remote.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/hydra-queue-runner/build-remote.cc b/src/hydra-queue-runner/build-remote.cc index f1c86e1d..3dec28ee 100644 --- a/src/hydra-queue-runner/build-remote.cc +++ b/src/hydra-queue-runner/build-remote.cc @@ -35,6 +35,8 @@ static void openConnection(Machine::ptr machine, Path tmpDir, int stderrFD, Chil child.pid = startProcess([&]() { + restoreSignals(); + if (dup2(to.readSide.get(), STDIN_FILENO) == -1) throw SysError("cannot dup input pipe to stdin");