diff options
Diffstat (limited to 'OpenSim/Framework/Data.MySQL')
-rw-r--r-- | OpenSim/Framework/Data.MySQL/MySQLGridData.cs | 18 | ||||
-rw-r--r-- | OpenSim/Framework/Data.MySQL/MySQLManager.cs | 6 |
2 files changed, 12 insertions, 12 deletions
diff --git a/OpenSim/Framework/Data.MySQL/MySQLGridData.cs b/OpenSim/Framework/Data.MySQL/MySQLGridData.cs index 5709bf0..9876ab1 100644 --- a/OpenSim/Framework/Data.MySQL/MySQLGridData.cs +++ b/OpenSim/Framework/Data.MySQL/MySQLGridData.cs | |||
@@ -96,7 +96,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
96 | /// <param name="xmax">Maximum X coordinate</param> | 96 | /// <param name="xmax">Maximum X coordinate</param> |
97 | /// <param name="ymax">Maximum Y coordinate</param> | 97 | /// <param name="ymax">Maximum Y coordinate</param> |
98 | /// <returns></returns> | 98 | /// <returns></returns> |
99 | public SimProfileData[] GetProfilesInRange(uint xmin, uint ymin, uint xmax, uint ymax) | 99 | public RegionProfileData[] GetProfilesInRange(uint xmin, uint ymin, uint xmax, uint ymax) |
100 | { | 100 | { |
101 | try | 101 | try |
102 | { | 102 | { |
@@ -111,9 +111,9 @@ namespace OpenSim.Framework.Data.MySQL | |||
111 | IDbCommand result = database.Query("SELECT * FROM regions WHERE locX >= ?xmin AND locX <= ?xmax AND locY >= ?ymin AND locY <= ?ymax", param); | 111 | IDbCommand result = database.Query("SELECT * FROM regions WHERE locX >= ?xmin AND locX <= ?xmax AND locY >= ?ymin AND locY <= ?ymax", param); |
112 | IDataReader reader = result.ExecuteReader(); | 112 | IDataReader reader = result.ExecuteReader(); |
113 | 113 | ||
114 | SimProfileData row; | 114 | RegionProfileData row; |
115 | 115 | ||
116 | List<SimProfileData> rows = new List<SimProfileData>(); | 116 | List<RegionProfileData> rows = new List<RegionProfileData>(); |
117 | 117 | ||
118 | while ((row = database.readSimRow(reader)) != null) | 118 | while ((row = database.readSimRow(reader)) != null) |
119 | { | 119 | { |
@@ -139,7 +139,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
139 | /// </summary> | 139 | /// </summary> |
140 | /// <param name="handle">Region location handle</param> | 140 | /// <param name="handle">Region location handle</param> |
141 | /// <returns>Sim profile</returns> | 141 | /// <returns>Sim profile</returns> |
142 | public SimProfileData GetProfileByHandle(ulong handle) | 142 | public RegionProfileData GetProfileByHandle(ulong handle) |
143 | { | 143 | { |
144 | try | 144 | try |
145 | { | 145 | { |
@@ -151,7 +151,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
151 | IDbCommand result = database.Query("SELECT * FROM regions WHERE regionHandle = ?handle", param); | 151 | IDbCommand result = database.Query("SELECT * FROM regions WHERE regionHandle = ?handle", param); |
152 | IDataReader reader = result.ExecuteReader(); | 152 | IDataReader reader = result.ExecuteReader(); |
153 | 153 | ||
154 | SimProfileData row = database.readSimRow(reader); | 154 | RegionProfileData row = database.readSimRow(reader); |
155 | reader.Close(); | 155 | reader.Close(); |
156 | result.Dispose(); | 156 | result.Dispose(); |
157 | 157 | ||
@@ -171,7 +171,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
171 | /// </summary> | 171 | /// </summary> |
172 | /// <param name="uuid">The region UUID</param> | 172 | /// <param name="uuid">The region UUID</param> |
173 | /// <returns>The sim profile</returns> | 173 | /// <returns>The sim profile</returns> |
174 | public SimProfileData GetProfileByLLUUID(LLUUID uuid) | 174 | public RegionProfileData GetProfileByLLUUID(LLUUID uuid) |
175 | { | 175 | { |
176 | try | 176 | try |
177 | { | 177 | { |
@@ -183,7 +183,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
183 | IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = ?uuid", param); | 183 | IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = ?uuid", param); |
184 | IDataReader reader = result.ExecuteReader(); | 184 | IDataReader reader = result.ExecuteReader(); |
185 | 185 | ||
186 | SimProfileData row = database.readSimRow(reader); | 186 | RegionProfileData row = database.readSimRow(reader); |
187 | reader.Close(); | 187 | reader.Close(); |
188 | result.Dispose(); | 188 | result.Dispose(); |
189 | 189 | ||
@@ -203,7 +203,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
203 | /// </summary> | 203 | /// </summary> |
204 | /// <param name="profile">The profile to add</param> | 204 | /// <param name="profile">The profile to add</param> |
205 | /// <returns>Successful?</returns> | 205 | /// <returns>Successful?</returns> |
206 | public DataResponse AddProfile(SimProfileData profile) | 206 | public DataResponse AddProfile(RegionProfileData profile) |
207 | { | 207 | { |
208 | lock (database) | 208 | lock (database) |
209 | { | 209 | { |
@@ -232,7 +232,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
232 | if (throwHissyFit) | 232 | if (throwHissyFit) |
233 | throw new Exception("CRYPTOWEAK AUTHENTICATE: Refusing to authenticate due to replay potential."); | 233 | throw new Exception("CRYPTOWEAK AUTHENTICATE: Refusing to authenticate due to replay potential."); |
234 | 234 | ||
235 | SimProfileData data = GetProfileByLLUUID(uuid); | 235 | RegionProfileData data = GetProfileByLLUUID(uuid); |
236 | 236 | ||
237 | return (handle == data.regionHandle && authkey == data.regionSecret); | 237 | return (handle == data.regionHandle && authkey == data.regionSecret); |
238 | } | 238 | } |
diff --git a/OpenSim/Framework/Data.MySQL/MySQLManager.cs b/OpenSim/Framework/Data.MySQL/MySQLManager.cs index d3f6976..8600d6b 100644 --- a/OpenSim/Framework/Data.MySQL/MySQLManager.cs +++ b/OpenSim/Framework/Data.MySQL/MySQLManager.cs | |||
@@ -267,9 +267,9 @@ namespace OpenSim.Framework.Data.MySQL | |||
267 | /// </summary> | 267 | /// </summary> |
268 | /// <param name="reader">An active database reader</param> | 268 | /// <param name="reader">An active database reader</param> |
269 | /// <returns>A region profile</returns> | 269 | /// <returns>A region profile</returns> |
270 | public SimProfileData readSimRow(IDataReader reader) | 270 | public RegionProfileData readSimRow(IDataReader reader) |
271 | { | 271 | { |
272 | SimProfileData retval = new SimProfileData(); | 272 | RegionProfileData retval = new RegionProfileData(); |
273 | 273 | ||
274 | if (reader.Read()) | 274 | if (reader.Read()) |
275 | { | 275 | { |
@@ -583,7 +583,7 @@ namespace OpenSim.Framework.Data.MySQL | |||
583 | /// </summary> | 583 | /// </summary> |
584 | /// <param name="profile">The region to insert</param> | 584 | /// <param name="profile">The region to insert</param> |
585 | /// <returns>Success?</returns> | 585 | /// <returns>Success?</returns> |
586 | public bool insertRegion(SimProfileData regiondata) | 586 | public bool insertRegion(RegionProfileData regiondata) |
587 | { | 587 | { |
588 | string sql = "REPLACE INTO regions (regionHandle, regionName, uuid, regionRecvKey, regionSecret, regionSendKey, regionDataURI, "; | 588 | string sql = "REPLACE INTO regions (regionHandle, regionName, uuid, regionRecvKey, regionSecret, regionSendKey, regionDataURI, "; |
589 | sql += "serverIP, serverPort, serverURI, locX, locY, locZ, eastOverrideHandle, westOverrideHandle, southOverrideHandle, northOverrideHandle, regionAssetURI, regionAssetRecvKey, "; | 589 | sql += "serverIP, serverPort, serverURI, locX, locY, locZ, eastOverrideHandle, westOverrideHandle, southOverrideHandle, northOverrideHandle, regionAssetURI, regionAssetRecvKey, "; |