http-server
http-server copied to clipboard
[Doubt] Updating epoll interest list Upon EAGAIN/EWOULDBLOCK while sending
Inside HandleEpollEvent function,
Upon EPOLLOUT, if EAGAIN/EWOULDBLOCK occurs, the client fd is being readded to epoll list,
but shouldn't it be just modified as done while doing recv?
EPOLLOUT https://github.com/trungams/http-server/blob/1c171367234d245fa9a5452c86354681bbfe383c/src/http_server.cc#L206-L207
EPOLLIN https://github.com/trungams/http-server/blob/1c171367234d245fa9a5452c86354681bbfe383c/src/http_server.cc#L180-L183
Also is it required to do this? or can we just skip this part without doing any modification to interest list and retry when EAGAIN/EWOULDBLOCK happens?
Thanks in advance,
-- Thanks a lot for opensourcing this project :)