mirror of
https://github.com/apple/swift-nio
synced 2026-11-30 05:28:44 +00:00
NIOCore: adjust the BSDSocketAPI for Windows (#2164)
Windows does not provide a definition for `socklen_t`. Create an internal typealias for it to provide source stability to the internal interfaces. Co-authored-by: George Barnett <gbarnett@apple.com> Co-authored-by: Cory Benfield <lukasa@apple.com>
This commit is contained in:
1 file changed
+2
@@ -57,6 +57,8 @@ import func WinSDK.inet_pton
|
||||
|
||||
import func WinSDK.GetLastError
|
||||
import func WinSDK.WSAGetLastError
|
||||
|
||||
internal typealias socklen_t = ucrt.size_t
|
||||
#elseif os(Linux) || os(Android)
|
||||
import Glibc
|
||||
import CNIOLinux
|
||||
|
||||
Reference in new issue
Block a user