diff options
author | Melanie | 2011-02-16 08:06:11 +0000 |
---|---|---|
committer | Melanie | 2011-02-16 08:06:11 +0000 |
commit | 918c12c965e822457807563acd4e16638a6bd3cc (patch) | |
tree | a910e27a3da8e3a1661434224230ad7e987d1070 /OpenSim/Services | |
parent | Catch HttpServer exception: mantis #5381 (diff) | |
download | opensim-SC_OLD-918c12c965e822457807563acd4e16638a6bd3cc.zip opensim-SC_OLD-918c12c965e822457807563acd4e16638a6bd3cc.tar.gz opensim-SC_OLD-918c12c965e822457807563acd4e16638a6bd3cc.tar.bz2 opensim-SC_OLD-918c12c965e822457807563acd4e16638a6bd3cc.tar.xz |
Change the QUERYACCESS method to eliminate spurious access denied messages
Diffstat (limited to 'OpenSim/Services')
-rw-r--r-- | OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs | 17 | ||||
-rw-r--r-- | OpenSim/Services/Interfaces/ISimulationService.cs | 2 |
2 files changed, 17 insertions, 2 deletions
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 | |||
256 | 256 | ||
257 | /// <summary> | 257 | /// <summary> |
258 | /// </summary> | 258 | /// </summary> |
259 | public bool QueryAccess(GridRegion destination, UUID id, Vector3 position) | 259 | public bool QueryAccess(GridRegion destination, UUID id, Vector3 position, out string reason) |
260 | { | 260 | { |
261 | reason = "Failed to contact destination"; | ||
262 | |||
261 | // m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: QueryAccess start, position={0}", position); | 263 | // m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: QueryAccess start, position={0}", position); |
262 | 264 | ||
263 | IPEndPoint ext = destination.ExternalEndPoint; | 265 | IPEndPoint ext = destination.ExternalEndPoint; |
@@ -283,8 +285,21 @@ namespace OpenSim.Services.Connectors.Simulation | |||
283 | 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"); | 285 | 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"); |
284 | return true; | 286 | return true; |
285 | } | 287 | } |
288 | |||
289 | reason = result["Message"]; | ||
290 | } | ||
291 | else | ||
292 | { | ||
293 | reason = "Communications failure"; | ||
286 | } | 294 | } |
295 | |||
296 | return false; | ||
287 | } | 297 | } |
298 | |||
299 | OSDMap resp = (OSDMap)result["_Result"]; | ||
300 | success = resp["success"].AsBoolean(); | ||
301 | reason = resp["reason"].AsString(); | ||
302 | |||
288 | return success; | 303 | return success; |
289 | } | 304 | } |
290 | catch (Exception e) | 305 | catch (Exception e) |
diff --git a/OpenSim/Services/Interfaces/ISimulationService.cs b/OpenSim/Services/Interfaces/ISimulationService.cs index 48a2185..b796757 100644 --- a/OpenSim/Services/Interfaces/ISimulationService.cs +++ b/OpenSim/Services/Interfaces/ISimulationService.cs | |||
@@ -60,7 +60,7 @@ namespace OpenSim.Services.Interfaces | |||
60 | 60 | ||
61 | bool RetrieveAgent(GridRegion destination, UUID id, out IAgentData agent); | 61 | bool RetrieveAgent(GridRegion destination, UUID id, out IAgentData agent); |
62 | 62 | ||
63 | bool QueryAccess(GridRegion destination, UUID id, Vector3 position); | 63 | bool QueryAccess(GridRegion destination, UUID id, Vector3 position, out string reason); |
64 | 64 | ||
65 | /// <summary> | 65 | /// <summary> |
66 | /// Message from receiving region to departing region, telling it got contacted by the client. | 66 | /// Message from receiving region to departing region, telling it got contacted by the client. |