From 3f4e7cb45c350319cd1d26668f15f808bcd80736 Mon Sep 17 00:00:00 2001 From: Guillaume Lessard Date: Thu, 17 Oct 2024 14:27:41 -0700 Subject: [PATCH] =?UTF-8?q?[windows]=20expose=20pipe=E2=80=99s=20buffer=20?= =?UTF-8?q?size=20parameter?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Sources/System/Internals/WindowsSyscallAdapters.swift | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Sources/System/Internals/WindowsSyscallAdapters.swift b/Sources/System/Internals/WindowsSyscallAdapters.swift index d470bd1..d56d33e 100644 --- a/Sources/System/Internals/WindowsSyscallAdapters.swift +++ b/Sources/System/Internals/WindowsSyscallAdapters.swift @@ -184,8 +184,10 @@ internal func pwrite( } @inline(__always) -internal func pipe(_ fds: UnsafeMutablePointer) -> CInt { - return _pipe(fds, 4096, _O_BINARY | _O_NOINHERIT); +internal func pipe( + _ fds: UnsafeMutablePointer, bytesReserved: UInt32 = 4096 +) -> CInt { +  return _pipe(fds, bytesReserved, _O_BINARY | _O_NOINHERIT); } @inline(__always)