Skip to content
Snippets Groups Projects
Commit ef51e48d authored by Serge Petrenko's avatar Serge Petrenko Committed by Vladimir Davydov
Browse files

coio: handle spurious wakeup correctly

coio_accept, coio_read, coio_write, coio_writev used to handle spurious
wakeups correctly: if the timeout hasn't passed yet, they would simply
retry reading (or writing) and fall asleep once again if no data is
ready.

This behaviour changed in the following patches:
577a640a ("coio: pass fd to
coio_accept") and 4f84859d ("Introduce
iostream wrapper for socket I/O").

Now the functions timeout on the very first spurious wakeup.

Fix this and add the appropriate unit tests.
parent 488c2986
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment