Skip to content

Commit 28fa9f0

Browse files
committed
fix: windows
1 parent 520b66b commit 28fa9f0

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

libraries/http_server/http_server/tcp_server.hh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -475,8 +475,6 @@ struct async_reactor {
475475
#else
476476
if (-1 == ::fcntl(socket_fd, F_SETFL, fcntl(socket_fd, F_GETFL, 0) | O_NONBLOCK)) continue;
477477
#endif
478-
#if __linux__
479-
480478
// ============================================
481479
// Find a free fiber for this new connection.
482480
int fiber_idx = 0;
@@ -486,6 +484,7 @@ struct async_reactor {
486484
fibers.resize((fibers.size() + 1) * 2);
487485
assert(fiber_idx < fibers.size());
488486
// ============================================
487+
#if __linux__
489488
this->epoll_add(socket_fd, EPOLLIN | EPOLLOUT | EPOLLRDHUP | EPOLLET, fiber_idx);
490489
#elif _WIN32
491490
this->epoll_add(socket_fd, EPOLLIN | EPOLLOUT | EPOLLRDHUP, fiber_idx);

0 commit comments

Comments
 (0)