summaryrefslogtreecommitdiffstats
path: root/src/server/sockets.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/sockets.cpp')
-rw-r--r--src/server/sockets.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/server/sockets.cpp b/src/server/sockets.cpp
index 1a52786..7c995f0 100644
--- a/src/server/sockets.cpp
+++ b/src/server/sockets.cpp
@@ -1,4 +1,5 @@
#include <errno.h>
+#include <stdio.h>
#include "sockets.hpp"
@@ -78,7 +79,7 @@ void EventSelector::Run()
{
exit_flag = false;
do {
- int res = poll(fds, max_fd, -1);
+ int res = poll(fds, max_fd+1, -1);
if(res < 0) {
if(errno == EINTR)