Fixed sender buffer (push to front if send or select successful).

This commit is contained in:
lotodore
2007-11-22 20:18:19 +00:00
parent 49e39adfbb
commit c0ba1a04e6
+2 -2
View File
@@ -230,7 +230,7 @@ SenderThread::Main()
{
// Select was successful - store the packet back in the main queue.
boost::mutex::scoped_lock lock(m_sendQueueMutex);
m_sendQueue.push_back(tmpData);
m_sendQueue.push_front(tmpData);
}
}
else // other errors than would block
@@ -249,7 +249,7 @@ SenderThread::Main()
tmpData.bytesSent += bytesSent;
// Send was partly successful - store the packet back in the main queue.
boost::mutex::scoped_lock lock(m_sendQueueMutex);
m_sendQueue.push_back(tmpData);
m_sendQueue.push_front(tmpData);
}
else
Msleep(SEND_TIMEOUT_MSEC);