From 918c12c965e822457807563acd4e16638a6bd3cc Mon Sep 17 00:00:00 2001
From: Melanie
Date: Wed, 16 Feb 2011 08:06:11 +0000
Subject: Change the QUERYACCESS method to eliminate spurious access denied
messages
---
.../Connectors/Simulation/SimulationServiceConnector.cs | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
(limited to 'OpenSim/Services/Connectors/Simulation')
diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
index cc6bffb..f6ee493 100644
--- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
@@ -256,8 +256,10 @@ namespace OpenSim.Services.Connectors.Simulation
///
///
- public bool QueryAccess(GridRegion destination, UUID id, Vector3 position)
+ public bool QueryAccess(GridRegion destination, UUID id, Vector3 position, out string reason)
{
+ reason = "Failed to contact destination";
+
// m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: QueryAccess start, position={0}", position);
IPEndPoint ext = destination.ExternalEndPoint;
@@ -283,8 +285,21 @@ namespace OpenSim.Services.Connectors.Simulation
m_log.Info("[REMOTE SIMULATION CONNECTOR]: The above web util error was caused by a TP to a sim that doesn't support QUERYACCESS and can be ignored");
return true;
}
+
+ reason = result["Message"];
+ }
+ else
+ {
+ reason = "Communications failure";
}
+
+ return false;
}
+
+ OSDMap resp = (OSDMap)result["_Result"];
+ success = resp["success"].AsBoolean();
+ reason = resp["reason"].AsString();
+
return success;
}
catch (Exception e)
--
cgit v1.1
From c6f2d66eae890bae56cdb9acf6b2691fe539b5f0 Mon Sep 17 00:00:00 2001
From: Diva Canto
Date: Wed, 16 Feb 2011 09:57:12 -0800
Subject: Fix bug introduced by Query Access. The response does not come in a
packaged _Result field, it comes as simple OSDMap with 2 fields in it. Also
in this commit: comment out irrelevant debug message on AuthService.
---
.../Connectors/Simulation/SimulationServiceConnector.cs | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
(limited to 'OpenSim/Services/Connectors/Simulation')
diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
index f6ee493..8aa88cb 100644
--- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
@@ -274,7 +274,11 @@ namespace OpenSim.Services.Connectors.Simulation
try
{
OSDMap result = WebUtil.ServiceOSDRequest(uri, request, "QUERYACCESS", 10000);
- bool success = result["Success"].AsBoolean();
+ bool success = result["success"].AsBoolean();
+ reason = result["reason"].AsString();
+
+ //m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: QueryAccess to {0} returned {1}", uri, success);
+
if (!success)
{
if (result.ContainsKey("Message"))
@@ -296,10 +300,6 @@ namespace OpenSim.Services.Connectors.Simulation
return false;
}
- OSDMap resp = (OSDMap)result["_Result"];
- success = resp["success"].AsBoolean();
- reason = resp["reason"].AsString();
-
return success;
}
catch (Exception e)
--
cgit v1.1
From 60d47836ce4bc25d6eed637f506a459dccde6b82 Mon Sep 17 00:00:00 2001
From: Justin Clark-Casey (justincc)
Date: Fri, 18 Feb 2011 22:00:52 +0000
Subject: minor: remove mono compiler warning
---
OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
(limited to 'OpenSim/Services/Connectors/Simulation')
diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
index 8aa88cb..463b2fb 100644
--- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
@@ -185,7 +185,7 @@ namespace OpenSim.Services.Connectors.Simulation
}
// unreachable
- return true;
+// return true;
}
///
--
cgit v1.1