Fix EAGAIN issue in acceptLoop().

This commit is contained in:
cheatfate 2020-07-15 01:07:03 +03:00
parent 63041b2d8f
commit 783f84aa4b
No known key found for this signature in database
GPG Key ID: 46ADD633A7201F95
1 changed files with 4 additions and 0 deletions

View File

@ -1477,6 +1477,10 @@ else:
let err = osLastError()
if int(err) == EINTR:
continue
elif int(err) == EAGAIN:
# This error appears only when server get closed, while acceptLoop()
# reader callback is already scheduled.
break
else:
## Critical unrecoverable error
raiseTransportOsError(err)