fds[0].fd = sockfd;
fds[0].events = POLLERR | POLLHUP;
/* Either poll for read or write possibility. */
- if (1 == mode) {
+ if (mode == 1) {
fds[0].events |= POLLIN | POLLPRI;
- } else if (0 == mode) {
+ } else if (mode == 0) {
fds[0].events |= POLLOUT;
} else {
abort();