Slow down the packet receiving code again after new reports of thread storms.

This commit is contained in:
Melanie
2009-10-09 12:17:55 +01:00
parent 77e48a6725
commit 23586b69a1

View File

@@ -198,9 +198,6 @@ namespace OpenMetaverse
// to AsyncBeginReceive
if (!m_shutdownFlag)
{
// start another receive - this keeps the server going!
AsyncBeginReceive();
// get the buffer that was created in AsyncBeginReceive
// this is the received data
//WrappedObject<UDPPacketBuffer> wrappedBuffer = (WrappedObject<UDPPacketBuffer>)iar.AsyncState;
@@ -219,7 +216,14 @@ namespace OpenMetaverse
}
catch (SocketException) { }
catch (ObjectDisposedException) { }
//finally { wrappedBuffer.Dispose(); }
finally
{
// wrappedBuffer.Dispose();
// start another receive - this keeps the server going!
AsyncBeginReceive();
}
}
}