参考:http://www.cnblogs.com/alyssaCui/archive/2013/04/01/2993886.html
struct pollfd 结构
struct pollfd {
int fd; /* 文件描述符 */
short events; /* 期待发生的事件 */
short revents; /* 实际发生了的事件 */
};
#include <poll.h>
int poll(struct pollfd fds[], nfds_t nfds, int timeout);
struct pollfd fds[] 用于存放需要检测其状态的socket描述符