aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-08-22 02:25:58 +0100
committerJustin Clark-Casey (justincc)2011-08-22 02:25:58 +0100
commitd74686fd51b4f88ef0040b7ef7d65facf8c00e04 (patch)
treeeb72b6c85b73191a61e7120e67a9a8e29a35cd8b /OpenSim
parentoops, fix build break from last commit (diff)
downloadopensim-SC-d74686fd51b4f88ef0040b7ef7d65facf8c00e04.zip
opensim-SC-d74686fd51b4f88ef0040b7ef7d65facf8c00e04.tar.gz
opensim-SC-d74686fd51b4f88ef0040b7ef7d65facf8c00e04.tar.bz2
opensim-SC-d74686fd51b4f88ef0040b7ef7d65facf8c00e04.tar.xz
read m_rpcHandlersKeepAlive under appropriate lock
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs6
1 files changed, 4 insertions, 2 deletions
diff --git a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs
index fce3671..af9b62f 100644
--- a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs
+++ b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs
@@ -803,9 +803,12 @@ namespace OpenSim.Framework.Servers.HttpServer
803 803
804 XmlRpcMethod method; 804 XmlRpcMethod method;
805 bool methodWasFound; 805 bool methodWasFound;
806 bool keepAlive = false;
806 lock (m_rpcHandlers) 807 lock (m_rpcHandlers)
807 { 808 {
808 methodWasFound = m_rpcHandlers.TryGetValue(methodName, out method); 809 methodWasFound = m_rpcHandlers.TryGetValue(methodName, out method);
810 if (methodWasFound)
811 keepAlive = m_rpcHandlersKeepAlive[methodName];
809 } 812 }
810 813
811 if (methodWasFound) 814 if (methodWasFound)
@@ -824,7 +827,6 @@ namespace OpenSim.Framework.Servers.HttpServer
824 } 827 }
825 xmlRprcRequest.Params.Add(request.Headers.Get(xff)); // Param[3] 828 xmlRprcRequest.Params.Add(request.Headers.Get(xff)); // Param[3]
826 829
827
828 try 830 try
829 { 831 {
830 xmlRpcResponse = method(xmlRprcRequest, request.RemoteIPEndPoint); 832 xmlRpcResponse = method(xmlRprcRequest, request.RemoteIPEndPoint);
@@ -846,7 +848,7 @@ namespace OpenSim.Framework.Servers.HttpServer
846 } 848 }
847 849
848 // if the method wasn't found, we can't determine KeepAlive state anyway, so lets do it only here 850 // if the method wasn't found, we can't determine KeepAlive state anyway, so lets do it only here
849 response.KeepAlive = m_rpcHandlersKeepAlive[methodName]; 851 response.KeepAlive = keepAlive;
850 } 852 }
851 else 853 else
852 { 854 {