diff options
Diffstat (limited to 'src/network/core')
-rw-r--r-- | src/network/core/tcp_listen.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/network/core/tcp_listen.h b/src/network/core/tcp_listen.h index 6c1d3e4ff..d2982363e 100644 --- a/src/network/core/tcp_listen.h +++ b/src/network/core/tcp_listen.h @@ -102,8 +102,7 @@ public: FD_ZERO(&write_fd); - Tsocket *cs; - FOR_ALL_ITEMS_FROM(Tsocket, idx, cs, 0) { + for (Tsocket *cs : Tsocket::Iterate()) { FD_SET(cs->sock, &read_fd); FD_SET(cs->sock, &write_fd); } @@ -122,7 +121,7 @@ public: } /* read stuff from clients */ - FOR_ALL_ITEMS_FROM(Tsocket, idx, cs, 0) { + for (Tsocket *cs : Tsocket::Iterate()) { cs->writable = !!FD_ISSET(cs->sock, &write_fd); if (FD_ISSET(cs->sock, &read_fd)) { cs->ReceivePackets(); |