-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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_poll
may not ignore EINTR if 0 file descriptors are passed
#11135
Comments
This was referenced May 18, 2023
@pitrou are you up to making a PR for this? |
I can try to do that. |
pitrou
added a commit
to pitrou/curl
that referenced
this issue
May 18, 2023
This was already done for the poll() and select() calls made directly from Curl_poll(), but was missed in Curl_wait_ms(), which is called when there are no fds to wait on. Fixes curl#11135
bch
pushed a commit
to bch/curl
that referenced
this issue
Jul 19, 2023
This was already done for the poll() and select() calls made directly from Curl_poll(), but was missed in Curl_wait_ms(), which is called when there are no fds to wait on. Fixes curl#11135 Closes curl#11143
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I encountered this potential issue when trying to investigate a user report.
In the general case,
Curl_poll
will translate EINTR into a no-error return so that the caller may retry:curl/lib/select.c
Lines 312 to 318 in a9f8fe2
However, if no valid fds are passed,
Curl_poll
delegates toCurl_wait_ms
which doesn't try to eliminate EINTR errors:curl/lib/select.c
Lines 94 to 104 in a9f8fe2
Curl_poll
is used fromCurl_multi_wait
where it's not obvious whether a non-zero number of file descriptors is always found.This might be a red herring, but I suppose it wouldn't hurt fixing
Curl_wait_ms
(and/orCurl_poll
) in any case.The text was updated successfully, but these errors were encountered: