Unix domain sockets and select
Just to make sure sure, one can call select on a Unix Domain socket. Correct? Also one can mix different types of sockets in a select statement. Is that corre开发者_Python百科ct?
Yes, that is correct. The only type of file descriptor you should not put in a select
call is a regular file, because regular files are always considered ready, even if reading from them would block.
of course,a socket/pipe/unix domain/msgqueue and something like that will be ok~
you may use sockpair right now , select / poll / epoll can get it.
精彩评论