From 980b7b04a6a2f97989b8dfed3941251eda8c09e0 Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Wed, 8 Jul 2020 17:19:02 +0300 Subject: [PATCH] Add a FIXME Change-Id: I7d54f77c5661b04616c04d1807966b9e1ccea485 --- net/Socket.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/net/Socket.cpp b/net/Socket.cpp index 2f35b5cce..98822919c 100644 --- a/net/Socket.cpp +++ b/net/Socket.cpp @@ -288,6 +288,11 @@ int SocketPoll::poll(int64_t timeoutMaxMicroS) } // This should only happen when we're stopping. + + // FIXME: A few dozen lines above we have potentially inserted new elements in _pollSockets, so + // clearly its size can now be larger than what it was when we came to this function, which got + // saved in the size variable. + if (_pollSockets.size() != size) return rc;