diff --git a/lib/roken/simple_exec.c b/lib/roken/simple_exec.c index f3c4dabc3..9cc33e754 100644 --- a/lib/roken/simple_exec.c +++ b/lib/roken/simple_exec.c @@ -197,7 +197,7 @@ pipe_execv(FILE **stdin_fd, FILE **stdout_fd, FILE **stderr_fd, close(err_fd[1]); } - closefrom(2); + closefrom(3); execv(file, argv); exit((errno == ENOENT) ? EX_NOTFOUND : EX_NOEXEC);