aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs
diff options
context:
space:
mode:
authorDiva Canto2009-09-24 13:33:58 -0700
committerDiva Canto2009-09-24 13:33:58 -0700
commitdd3d52ae1faefbca85e2fe8d8cea67f7db4005ac (patch)
tree659b977f1ab6b7fd5def36fe8c967953dc1edeb5 /OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs
parentMerge branch 'master' of ssh://justincc@opensimulator.org/var/git/opensim (diff)
downloadopensim-SC_OLD-dd3d52ae1faefbca85e2fe8d8cea67f7db4005ac.zip
opensim-SC_OLD-dd3d52ae1faefbca85e2fe8d8cea67f7db4005ac.tar.gz
opensim-SC_OLD-dd3d52ae1faefbca85e2fe8d8cea67f7db4005ac.tar.bz2
opensim-SC_OLD-dd3d52ae1faefbca85e2fe8d8cea67f7db4005ac.tar.xz
Added test GridClient, which allowed me to remove a few bugs out of the new code.
Diffstat (limited to 'OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs')
-rw-r--r--OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs11
1 files changed, 7 insertions, 4 deletions
diff --git a/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs b/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs
index e72c2eb..eaeed6f 100644
--- a/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs
+++ b/OpenSim/Server/Handlers/Grid/GridServerPostHandler.cs
@@ -63,6 +63,7 @@ namespace OpenSim.Server.Handlers.Grid
63 StreamReader sr = new StreamReader(requestData); 63 StreamReader sr = new StreamReader(requestData);
64 string body = sr.ReadToEnd(); 64 string body = sr.ReadToEnd();
65 sr.Close(); 65 sr.Close();
66 body = body.Trim();
66 67
67 Dictionary<string, string> request = 68 Dictionary<string, string> request =
68 ServerUtils.ParseQueryString(body); 69 ServerUtils.ParseQueryString(body);
@@ -98,11 +99,11 @@ namespace OpenSim.Server.Handlers.Grid
98 case "get_region_range": 99 case "get_region_range":
99 return GetRegionRange(request); 100 return GetRegionRange(request);
100 101
101 default:
102 m_log.DebugFormat("[GRID HANDLER]: unknown method request {0}", method);
103 return FailureResult();
104 } 102 }
105 103
104 m_log.DebugFormat("[GRID HANDLER XXX]: unknown method {0} request {1}", method.Length, method);
105 return FailureResult();
106
106 } 107 }
107 108
108 #region Method-specific handlers 109 #region Method-specific handlers
@@ -155,11 +156,12 @@ namespace OpenSim.Server.Handlers.Grid
155 156
156 UUID regionID = UUID.Zero; 157 UUID regionID = UUID.Zero;
157 if (request["REGIONID"] != null) 158 if (request["REGIONID"] != null)
158 UUID.TryParse(request["REGIONID"], out scopeID); 159 UUID.TryParse(request["REGIONID"], out regionID);
159 else 160 else
160 m_log.WarnFormat("[GRID HANDLER]: no regionID in request to get neighbours"); 161 m_log.WarnFormat("[GRID HANDLER]: no regionID in request to get neighbours");
161 162
162 List<GridRegion> rinfos = m_GridService.GetNeighbours(scopeID, regionID); 163 List<GridRegion> rinfos = m_GridService.GetNeighbours(scopeID, regionID);
164 //m_log.DebugFormat("[GRID HANDLER]: neighbours for region {0}: {1}", regionID, rinfos.Count);
163 165
164 Dictionary<string, object> result = new Dictionary<string, object>(); 166 Dictionary<string, object> result = new Dictionary<string, object>();
165 int i = 0; 167 int i = 0;
@@ -171,6 +173,7 @@ namespace OpenSim.Server.Handlers.Grid
171 } 173 }
172 174
173 string xmlString = ServerUtils.BuildXmlResponse(result); 175 string xmlString = ServerUtils.BuildXmlResponse(result);
176 //m_log.DebugFormat("[GRID HANDLER]: resp string: {0}", xmlString);
174 UTF8Encoding encoding = new UTF8Encoding(); 177 UTF8Encoding encoding = new UTF8Encoding();
175 return encoding.GetBytes(xmlString); 178 return encoding.GetBytes(xmlString);
176 179