From 76d18ce4c66f5e654a3743811e426e8b48d230ca Mon Sep 17 00:00:00 2001 From: Jason Lynch Date: Tue, 5 Feb 2013 08:48:37 -0600 Subject: [PATCH] Fix duplication/dropping of messages in certain instances. When multiple messages are processed at once, if one of the messages is flagged for redirection, the wrong array is accessed, potentially causing the redirected message to be dropped and another message to be duplicated. --- src/core/coresession.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/coresession.cpp b/src/core/coresession.cpp index 9b1395bb..d7a330a0 100644 --- a/src/core/coresession.cpp +++ b/src/core/coresession.cpp @@ -350,7 +350,7 @@ void CoreSession::processMessages() // recheck if there exists a buffer to store a redirected message in for (int i = 0; i < redirectedMessages.count(); i++) { - const RawMessage &rawMsg = _messageQueue.at(i); + const RawMessage &rawMsg = redirectedMessages.at(i); if (bufferInfoCache.contains(rawMsg.networkId) && bufferInfoCache[rawMsg.networkId].contains(rawMsg.target)) { bufferInfo = bufferInfoCache[rawMsg.networkId][rawMsg.target]; } -- 2.20.1