diff --git a/ncat/ncat_listen.c b/ncat/ncat_listen.c index 20b14b7db..c32296057 100644 --- a/ncat/ncat_listen.c +++ b/ncat/ncat_listen.c @@ -1155,7 +1155,7 @@ static int chat_announce_connect(int fd, const union sockaddr_u *su) strbuf_sprintf(&buf, &size, &offset, " already connected: "); count = 0; - for (i = 0; i < client_fdlist.fdmax; i++) { + for (i = 0; i <= client_fdlist.fdmax; i++) { union sockaddr_u su; socklen_t len = sizeof(su.storage);