Skip to content

Commit 1bb30c5

Browse files
daurnimatorandrewrk
authored andcommitted
std.ChildProcess: pass CLOEXEC when creating error pipe
1 parent 04361dd commit 1bb30c5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/std/child_process.zig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,7 @@ pub const ChildProcess = struct {
401401
// end with eventfd
402402
break :blk [2]os.fd_t{ fd, fd };
403403
} else {
404-
break :blk try os.pipe();
404+
break :blk try os.pipe2(os.O_CLOEXEC);
405405
}
406406
};
407407
errdefer destroyPipe(err_pipe);

0 commit comments

Comments
 (0)