All pastes #961985 Raw Edit

Untitled

public text v1 · immutable
#961985 ·published 2008-03-29 11:43 UTC
rendered paste body
Index: src/common/BufferedNetworkMessage.cxx
===================================================================
--- src/common/BufferedNetworkMessage.cxx	(revision 16825)
+++ src/common/BufferedNetworkMessage.cxx	(working copy)
@@ -380,7 +380,8 @@
     if ((*itr) && (handler == (*itr)->recipent))  // just kill the message and data, it'll be pulled from the list on the next update pass
     {
       delete(*itr);
-      pendingOutgoingMesages.erase(itr++);
+      pendingOutgoingMesages.erase(itr);
+      itr = pendingOutgoingMesages.begin();
     }
     else
       itr++;
@@ -391,8 +392,9 @@
   {
     if ((*qItr) && (handler == (*qItr)->recipent))  // just kill the message and data, it'll be pulled from the list on the next update pass
     {
-      delete(*qItr);
-      outgoingQueue.erase(qItr++);
+        delete(*qItr);
+        outgoingQueue.erase(qItr);
+        qItr = outgoingQueue.begin();
     }
     else
       qItr++;