chriskohlhoff / asio

Asio C++ Library
http://think-async.com/Asio
4.98k stars 1.22k forks source link

epoll reactor cannot detect stream socket peer close event #1561

Open Chilledheart opened 3 hours ago

Chilledheart commented 3 hours ago

from man epoll_ctl:

   EPOLLRDHUP (since Linux 2.6.17)
          Stream socket peer closed connection, or shut down writing half of connection.  (This flag is especially useful for writing simple code to detect  peer  shutdown  when  using
          edge-triggered monitoring.)

However, this event is never used in epoll_reactor.ipp.