read m_rpcHandlersKeepAlive under appropriate lock
parent
c587b0a3a3
commit
d74686fd51
|
@ -803,9 +803,12 @@ namespace OpenSim.Framework.Servers.HttpServer
|
||||||
|
|
||||||
XmlRpcMethod method;
|
XmlRpcMethod method;
|
||||||
bool methodWasFound;
|
bool methodWasFound;
|
||||||
|
bool keepAlive = false;
|
||||||
lock (m_rpcHandlers)
|
lock (m_rpcHandlers)
|
||||||
{
|
{
|
||||||
methodWasFound = m_rpcHandlers.TryGetValue(methodName, out method);
|
methodWasFound = m_rpcHandlers.TryGetValue(methodName, out method);
|
||||||
|
if (methodWasFound)
|
||||||
|
keepAlive = m_rpcHandlersKeepAlive[methodName];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (methodWasFound)
|
if (methodWasFound)
|
||||||
|
@ -824,7 +827,6 @@ namespace OpenSim.Framework.Servers.HttpServer
|
||||||
}
|
}
|
||||||
xmlRprcRequest.Params.Add(request.Headers.Get(xff)); // Param[3]
|
xmlRprcRequest.Params.Add(request.Headers.Get(xff)); // Param[3]
|
||||||
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
xmlRpcResponse = method(xmlRprcRequest, request.RemoteIPEndPoint);
|
xmlRpcResponse = method(xmlRprcRequest, request.RemoteIPEndPoint);
|
||||||
|
@ -846,7 +848,7 @@ namespace OpenSim.Framework.Servers.HttpServer
|
||||||
}
|
}
|
||||||
|
|
||||||
// if the method wasn't found, we can't determine KeepAlive state anyway, so lets do it only here
|
// if the method wasn't found, we can't determine KeepAlive state anyway, so lets do it only here
|
||||||
response.KeepAlive = m_rpcHandlersKeepAlive[methodName];
|
response.KeepAlive = keepAlive;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue