You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Instead of using a large fixed-sized buffer, we can treat the structure as dynamically-sized and reallocate it when it gets full. Winsock functions read the size of the array from the count field in order to support the array to exceed 64 as needed. The only caveat is that we can't use the FD_SET macro because it has to use the compile-time size.
The text was updated successfully, but these errors were encountered:
This makes `fd_set` on Windows growable by adding additional space to the storing buffer, which effectively extends `fd_set.fd_array` capacity.
Follow-up for swiftlang#4954. Resolvesswiftlang#4958.
The
fd_set
structure on Windows has a trailing array of socket that defaults to size 64, which we override to 1024 https://github.com/apple/swift-corelibs-foundation/blob/06072877b110c4ba5501ddc012830c1072f7198c/CoreFoundation/Base.subproj/CoreFoundation_Prefix.h#L133C1-L133C24 .Instead of using a large fixed-sized buffer, we can treat the structure as dynamically-sized and reallocate it when it gets full. Winsock functions read the size of the array from the count field in order to support the array to exceed 64 as needed. The only caveat is that we can't use the
FD_SET
macro because it has to use the compile-time size.The text was updated successfully, but these errors were encountered: