1. 程式人生 > >第27月第18天 epoll lt et

第27月第18天 epoll lt et

1.

 

While the usage of epoll when employed as a level-triggered interface
       does have the same semantics as poll(2)

 

int addfd(int epollfd,int fd, bool enable_et)
{
    struct epoll_event event;
    event.data.fd = fd;
    event.events = EPOLLIN;
    if(enable_et)
    {
        
event.events |= EPOLLET; } epoll_ctl(epollfd,EPOLL_CTL_ADD,fd,&event); setnonblocking(fd); }

 

 

 

http://www.man7.org/linux/man-pages/man7/epoll.7.html

 

http://www.cnblogs.com/charlesblc/p/5521086.html

https://github.com/Tianxintong/LT_ET