Skip to content

Commit 154cbf7

Browse files
authored
Merge pull request apple#205 from glessard/1.4.0-pipe-correction
[windows] expose pipe’s buffer size parameter
2 parents 5cd7ead + 3f4e7cb commit 154cbf7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Sources/System/Internals/WindowsSyscallAdapters.swift

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -184,8 +184,10 @@ internal func pwrite(
184184
}
185185

186186
@inline(__always)
187-
internal func pipe(_ fds: UnsafeMutablePointer<Int32>) -> CInt {
188-
return _pipe(fds, 4096, _O_BINARY | _O_NOINHERIT);
187+
internal func pipe(
188+
_ fds: UnsafeMutablePointer<Int32>, bytesReserved: UInt32 = 4096
189+
) -> CInt {
190+
  return _pipe(fds, bytesReserved, _O_BINARY | _O_NOINHERIT);
189191
}
190192

191193
@inline(__always)

0 commit comments

Comments
 (0)