Disable compiling with poll() on macOS #393
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I've noticed recently that when using the bundled curl version on macOS, very occasionally curl will get "stuck" in the TCP connection phase when using the multi interface. Apparently this is caused by the
poll()
implementation not behaving quite as the POSIX standard says it should on some macOS versions. (Curl usespoll()
/select()
to check if a socket has finished connecting without blocking, even if you are not using those functions to poll read/write readiness.)This originally was a problem just for macOS 10.12, but after a recent update it seems like this regression might have come back in 10.15. It is more reliable to just disable
poll()
completely on macOS, which the official build configuration does here: https://github.com/curl/curl/blob/1e19eceb50d6d8b9c9b37e2f8e1259b2f311c82a/m4/curl-functions.m4#L4999-L5010See also curl/curl#1057 when this was originally reported way back in the day.