diff --git a/Changes b/Changes index 05b0048c9..8c5a6beb6 100644 --- a/Changes +++ b/Changes @@ -2410,3 +2410,6 @@ - Split up PROTOCTL line, since with the addition of ESVID we exceeded MAXPARA when using ZIP links. This caused an odd charset warning upon link. +- Poll I/O engine: get_client_by_pollfd() may return -1 when there's a race + condition. Don't abort, instead just skip those clients. + This fixes a crash I had on /SQUIT. diff --git a/src/s_bsd.c b/src/s_bsd.c index 7676b56de..d1475688a 100644 --- a/src/s_bsd.c +++ b/src/s_bsd.c @@ -204,8 +204,7 @@ int v; if ((fd < 0) || (fd >= MAXCONNECTIONS)) abort(); v = pollfd_to_client[fd]; - if ((v < 0) && (v != POLL_RESOLVER)) - abort(); + /* v may be negative, both when it's POLL_RESOLVER and during a race condition */ return v; } #else