@@ -899,7 +899,6 @@ pub const ChildProcess = struct {
899899 & tmp_hChildStd_Rd ,
900900 & tmp_hChildStd_Wr ,
901901 & saAttr ,
902- PipeDirection .child_to_parent ,
903902 );
904903 g_hChildStd_OUT_Rd = tmp_hChildStd_Rd ;
905904 g_hChildStd_OUT_Wr = tmp_hChildStd_Wr ;
@@ -926,7 +925,6 @@ pub const ChildProcess = struct {
926925 & tmp_hChildStd_Rd ,
927926 & tmp_hChildStd_Wr ,
928927 & saAttr ,
929- PipeDirection .child_to_parent ,
930928 );
931929 g_hChildStd_ERR_Rd = tmp_hChildStd_Rd ;
932930 g_hChildStd_ERR_Wr = tmp_hChildStd_Wr ;
@@ -1133,7 +1131,7 @@ pub const ChildProcess = struct {
11331131const PortPipeReturn = if (builtin .os .tag == .windows ) [2 ]windows .HANDLE else [2 ]os .fd_t ;
11341132
11351133/// Portable pipe creation without handle inheritance
1136- pub fn portablePipe () ! PortPipeReturn {
1134+ pub inline fn portablePipe () ! PortPipeReturn {
11371135 // TODO think how to offer user an interface to lpSecurityDescriptor
11381136 var pipe_new : PortPipeReturn = undefined ;
11391137 if (builtin .os .tag == .windows ) {
@@ -1529,7 +1527,6 @@ pub fn windowsMakeAsyncPipe(
15291527 rd : * windows.HANDLE ,
15301528 wr : * windows.HANDLE ,
15311529 sattr : * const windows.SECURITY_ATTRIBUTES ,
1532- direction : ChildProcess.PipeDirection ,
15331530) ! void {
15341531 var tmp_bufw : [128 ]u16 = undefined ;
15351532
@@ -1585,10 +1582,6 @@ pub fn windowsMakeAsyncPipe(
15851582 }
15861583 errdefer os .close (write_handle );
15871584
1588- switch (direction ) {
1589- .child_to_parent = > try windows .SetHandleInformation (read_handle , windows .HANDLE_FLAG_INHERIT , windows .HANDLE_FLAG_INHERIT ),
1590- .parent_to_child = > try windows .SetHandleInformation (write_handle , windows .HANDLE_FLAG_INHERIT , windows .HANDLE_FLAG_INHERIT ),
1591- }
15921585 rd .* = read_handle ;
15931586 wr .* = write_handle ;
15941587}
0 commit comments