From cfce0aa4482c50e3046ae44fe76d71fb70c82201 Mon Sep 17 00:00:00 2001 From: Melanie Date: Wed, 16 Feb 2011 05:22:05 +0100 Subject: Change the QUERYACCESS method to eliminate spurious access denied messages --- OpenSim/Server/Handlers/Simulation/AgentHandlers.cs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'OpenSim/Server/Handlers/Simulation/AgentHandlers.cs') diff --git a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs index 448e321..616aef3 100644 --- a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs +++ b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs @@ -346,10 +346,17 @@ namespace OpenSim.Server.Handlers.Simulation GridRegion destination = new GridRegion(); destination.RegionID = regionID; - bool result = m_SimulationService.QueryAccess(destination, id, position); + string reason; + bool result = m_SimulationService.QueryAccess(destination, id, position, out reason); responsedata["int_response_code"] = HttpStatusCode.OK; - responsedata["str_response_string"] = result.ToString(); + + OSDMap resp = new OSDMap(2); + + resp["success"] = OSD.FromBoolean(result); + resp["reason"] = OSD.FromString(reason); + + responsedata["str_response_string"] = OSDParser.SerializeJsonString(resp); } protected virtual void DoAgentGet(Hashtable request, Hashtable responsedata, UUID id, UUID regionID) -- cgit v1.1