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
Hi,
I was questioning if this ifdefs regarding sleep portability is still required, at the top of the multi-single example: https://github.com/curl/curl/blob/master/docs/examples/multi-single.c#L37 ?
I think this should be part of the curl library itself, if it isn't already 😄 .
#ifdef _WIN32 #define WAITMS(x) Sleep(x) #else /* Portable sleep for platforms other than Windows. */ #define WAITMS(x) \ struct timeval wait = { 0, (x) * 1000 }; \ (void)select(0, NULL, NULL, NULL, &wait) #endif
Regards, Melroy van den Berg
The text was updated successfully, but these errors were encountered:
I think this should be part of the curl library itself, if it isn't already
You mean add a curl_sleep()? I don't see much use of it.
Sorry, something went wrong.
WAITMS() is not even used in the example code ... 😄 I'll remove it.
WAITMS()
examples/multi-single.c: remove WAITMS()
fdc5ff2
As it isn't used. Reported-by: Melroy van den Berg Fixes #8200
e1b0410
Thank you Daniel. This is what I was thinking as well.
I think this multi_poll code has a sleep. To avoid busy waiting.
Successfully merging a pull request may close this issue.
danger89 commentedDec 30, 2021
•
edited
Hi,
I was questioning if this ifdefs regarding sleep portability is still required, at the top of the multi-single example: https://github.com/curl/curl/blob/master/docs/examples/multi-single.c#L37 ?
I think this should be part of the curl library itself, if it isn't already😄 .
Regards,
Melroy van den Berg
The text was updated successfully, but these errors were encountered: