DEBUG(2, "start %s %s \n", s->file, s->param);
if (pipe(pipefd) == -1) {
- ERROR("Failed to create pipe\n");
+ ERROR("Failed to create pipe: %m\n");
return;
}
if (pid) {
close(pipefd[1]);
+ fcntl(pipefd[0], F_SETFD, FD_CLOEXEC);
s->fd.stream.string_data = true,
s->fd.stream.notify_read = pipe_cb,
runqueue_process_add(q, &s->proc, pid);