handle also EAGAIN together with EWOULDBLOCK

This commit is contained in:
Omar Polo 2021-02-07 12:04:11 +00:00
parent 2564eddee4
commit cfb8a77fd4
1 changed files with 1 additions and 1 deletions

View File

@ -984,7 +984,7 @@ do_accept(int sock, struct tls *ctx, struct pollfd *fds, struct client *clients)
len = sizeof(addr);
if ((fd = accept(sock, (struct sockaddr*)&addr, &len)) == -1) {
if (errno == EWOULDBLOCK)
if (errno == EWOULDBLOCK || errno == EAGAIN)
return;
fatal("accept: %s", strerror(errno));
}