aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Server/Handlers/Simulation/AgentHandlers.cs7
-rw-r--r--OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs4
2 files changed, 9 insertions, 2 deletions
diff --git a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs
index 99ae7f0..012b14e 100644
--- a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs
+++ b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs
@@ -144,13 +144,16 @@ namespace OpenSim.Server.Handlers.Simulation
144 144
145 responsedata["int_response_code"] = HttpStatusCode.OK; 145 responsedata["int_response_code"] = HttpStatusCode.OK;
146 146
147 OSDMap resp = new OSDMap(2); 147 OSDMap resp = new OSDMap(3);
148 148
149 resp["success"] = OSD.FromBoolean(result); 149 resp["success"] = OSD.FromBoolean(result);
150 resp["reason"] = OSD.FromString(reason); 150 resp["reason"] = OSD.FromString(reason);
151 resp["version"] = OSD.FromString(version); 151 resp["version"] = OSD.FromString(version);
152 152
153 responsedata["str_response_string"] = OSDParser.SerializeJsonString(resp); 153 // We must preserve defaults here, otherwise a false "success" will not be put into the JSON map!
154 responsedata["str_response_string"] = OSDParser.SerializeJsonString(resp, true);
155
156// Console.WriteLine("str_response_string [{0}]", responsedata["str_response_string"]);
154 } 157 }
155 158
156 protected virtual void DoAgentGet(Hashtable request, Hashtable responsedata, UUID id, UUID regionID) 159 protected virtual void DoAgentGet(Hashtable request, Hashtable responsedata, UUID id, UUID regionID)
diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
index cc46ba8..032beb5 100644
--- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
@@ -320,6 +320,10 @@ namespace OpenSim.Services.Connectors.Simulation
320 { 320 {
321 OSDMap data = (OSDMap)result["_Result"]; 321 OSDMap data = (OSDMap)result["_Result"];
322 322
323 // FIXME: If there is a _Result map then it's the success key here that indicates the true success
324 // or failure, not the sibling result node.
325 success = data["success"];
326
323 reason = data["reason"].AsString(); 327 reason = data["reason"].AsString();
324 if (data["version"] != null && data["version"].AsString() != string.Empty) 328 if (data["version"] != null && data["version"].AsString() != string.Empty)
325 version = data["version"].AsString(); 329 version = data["version"].AsString();