aboutsummaryrefslogtreecommitdiffstats
path: root/executor/executor_runner.h
diff options
context:
space:
mode:
Diffstat (limited to 'executor/executor_runner.h')
-rw-r--r--executor/executor_runner.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/executor/executor_runner.h b/executor/executor_runner.h
index 57d63f6a7..766669dda 100644
--- a/executor/executor_runner.h
+++ b/executor/executor_runner.h
@@ -797,5 +797,11 @@ static void runner(char** argv, int argc)
fail("signal(SIGBUS) failed");
Connection conn(manager_addr, manager_port);
+
+ // This is required to make Subprocess fd remapping logic work.
+ // kCoverFilterFd is the largest fd we set in the child processes.
+ for (int fd = conn.FD(); fd < kCoverFilterFd;)
+ fd = dup(fd);
+
Runner(conn, name, argv[0]);
}