summaryrefslogtreecommitdiffhomepage
path: root/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'main.c')
-rw-r--r--main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.c b/main.c
index 72ddc49..8ed346c 100644
--- a/main.c
+++ b/main.c
@@ -73,7 +73,7 @@ int main(int argc, char ** argv)
for (int i = 0; i < nfds; ++i)
{
fds[i].fd = -1;
- fds[i].events = POLLIN | POLLOUT;
+ fds[i].events = POLLIN; // TODO: Handle yielded writes
data[i] = NULL;
}
const int server = open_server(NULL, service);
@@ -91,7 +91,7 @@ int main(int argc, char ** argv)
return 5;
for (int i = 0; i < nfds; ++i)
{
- if (-1 == fds[i].fd)
+ if (-1 == fds[i].fd || 0 == fds[i].revents)
continue;
if (NULL == data[i])
{