mirror of
https://github.com/opensim/opensim.git
synced 2026-08-06 01:06:30 +08:00
* Read scene_throttle_bps from the config file and use it
* Minor formatting cleanup
This commit is contained in:
@@ -138,15 +138,17 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||
#endregion Environment.TickCount Measurement
|
||||
|
||||
m_circuitManager = circuitManager;
|
||||
int sceneThrottleBps = 0;
|
||||
|
||||
IConfig config = configSource.Configs["ClientStack.LindenUDP"];
|
||||
if (config != null)
|
||||
{
|
||||
m_recvBufferSize = config.GetInt("client_socket_rcvbuf_size", 0);
|
||||
sceneThrottleBps = config.GetInt("scene_throttle_max_bps", 0);
|
||||
}
|
||||
|
||||
// TODO: Config support for throttling the entire connection
|
||||
m_throttle = new TokenBucket(null, 0, 0);
|
||||
m_throttle = new TokenBucket(null, sceneThrottleBps, sceneThrottleBps);
|
||||
m_throttleRates = new ThrottleRates(configSource);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user