Skip to content

Commit

Permalink
Add NIO patch on CI
Browse files Browse the repository at this point in the history
  • Loading branch information
finagolfin committed Dec 12, 2024
1 parent a9f0e23 commit 6e9ee6d
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions swift-nio-filesystem.patch
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,25 @@ index 3fc7d561..50e0482a 100644
#else
return "/tmp"
#endif
diff --git a/Sources/NIOFileSystem/Internal/System Calls/Syscall.swift b/Sources/NIOFileSystem/Internal/System Calls/Syscall.swift
index de532594..fe031870 100644
--- a/Sources/NIOFileSystem/Internal/System Calls/Syscall.swift
+++ b/Sources/NIOFileSystem/Internal/System Calls/Syscall.swift
@@ -400,14 +400,7 @@ public enum Libc {
return valueOrErrno {
pathBytes.withUnsafeMutableBufferPointer { pointer in
// The array must be terminated with a nil.
- #if os(Android)
- libc_fts_open(
- [pointer.baseAddress!, unsafeBitCast(0, to: UnsafeMutablePointer<CInterop.PlatformChar>.self)],
- options.rawValue
- )
- #else
libc_fts_open([pointer.baseAddress, nil], options.rawValue)
- #endif
}
}
}
diff --git a/Sources/NIOFileSystem/Internal/System Calls/Syscalls.swift b/Sources/NIOFileSystem/Internal/System Calls/Syscalls.swift
index 1e9c1661..2a4935e7 100644
--- a/Sources/NIOFileSystem/Internal/System Calls/Syscalls.swift
Expand Down

0 comments on commit 6e9ee6d

Please sign in to comment.