Chinaunix
标题:
求助关于epoll里的eventmask
[打印本页]
作者:
gamegjx
时间:
2013-06-19 16:42
标题:
求助关于epoll里的eventmask
当epoll里侦听的event事件时候
当event等于1时,就是代表select.EPOLLIN
当event等于4时,就是代表select.EPOLLOUT
但是当客户端断开时,然后我调用socket.send后
event就等于25了
再之后
event就等于24了
请问一下
当event等于24、以及25的时候,分别代表什么意思呢?
作者:
timespace
时间:
2013-06-19 18:00
从文档里猜测吧
Python 2.6.6 (r266:84292, Feb 21 2013, 23:54:59)
[GCC 4.4.7 20120313 (Red Hat 4.4.7-3)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import select
>>> help(select)
DATA
EPOLLERR = 8
EPOLLET = -2147483648
EPOLLHUP = 16
EPOLLIN = 1
EPOLLMSG = 1024
EPOLLONESHOT = 1073741824
EPOLLOUT = 4
EPOLLPRI = 2
EPOLLRDBAND = 128
EPOLLRDNORM = 64
EPOLLWRBAND = 512
EPOLLWRNORM = 256
复制代码
欢迎光临 Chinaunix (http://bbs.chinaunix.net/)
Powered by Discuz! X3.2