-
-
Notifications
You must be signed in to change notification settings - Fork 6.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
curl_multi_poll always returns immediately if the wakeup socket has been disconnected #6132
Labels
Comments
tomalakgeretkal
added a commit
to tomalakgeretkal/curl
that referenced
this issue
Oct 26, 2020
This problem reappear when iphone's OS version update to 16.x. |
My base libcurl version is 7.80.0, and pick your commit to build But this won't happen when I use libcurl 7.85.0, are there any other commits affect this problem? @bagder |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
curl_multi_poll
delegates toCurl_multi_wait
, which checksmulti->wakeup_pair[0]
for POLLIN activity then attempts to read from it.Unfortunately, waking an iPad breaks the wakeup socket pair, triggering a
POLLIN
event and resulting inSOCKERRNO
being set toENOTCONN
inCurl_multi_wait
's final#ifdef ENABLE_WAKEUP
block.This condition, and other possible error conditions on the wakeup socket, are not handled, so the condition remains on the FD and
curl_multi_poll
will never block again.Even if the iOS wake scenario is to be considered an edge case, it seems to me we'd be best off looking for and handling any wakeup socket errors anyway.
The text was updated successfully, but these errors were encountered: