Skip to content

Commit 760333b

Browse files
committed
Merge branch 'tcpserv' of https://github.com/tux3/toxcore
2 parents 5c87c7b + dee6c72 commit 760333b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

toxcore/TCP_server.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -818,9 +818,10 @@ static sock_t new_listening_TCP_socket(int family, uint16_t port)
818818
return ~0;
819819
}
820820

821-
int ok = 1;
822821
#ifndef TCP_SERVER_USE_EPOLL
823-
ok = set_socket_nonblock(sock);
822+
int ok = set_socket_nonblock(sock);
823+
#else
824+
int ok = 1;
824825
#endif
825826

826827
if (ok && family == AF_INET6) {

0 commit comments

Comments
 (0)