mirror of
https://github.com/apple/swift-nio-ssl
synced 2026-11-27 05:04:24 +00:00
Motivation: Right now we make a bunch of naked syscalls that don't correctly handle reporting errno or catching EINTR. We can't use the NIO Posix enum to fix this for us because it's internal, and because it doesn't have the function we need. Instead, we create a temporary port of those functions. Ideally we'd reconcile these at some time in the future. Modifications: Add a port of the Posix enum and its core functions. Improve wrapErrorIsNullReturnCall to be more useful. Adopt the posix functions. Result: Better safety in the face of EINTR. Better reporting of errnos.