diff options
Diffstat (limited to 'OpenSim/Framework/Data.SQLite')
-rw-r--r-- | OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs | 10 | ||||
-rw-r--r-- | OpenSim/Framework/Data.SQLite/SQLiteGridData.cs | 4 | ||||
-rw-r--r-- | OpenSim/Framework/Data.SQLite/SQLiteUserData.cs | 12 |
3 files changed, 13 insertions, 13 deletions
diff --git a/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs b/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs index bf43e6e..6199911 100644 --- a/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs +++ b/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs | |||
@@ -79,7 +79,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
79 | public AssetBase FetchAsset(LLUUID uuid) | 79 | public AssetBase FetchAsset(LLUUID uuid) |
80 | { | 80 | { |
81 | AssetBase asset = new AssetBase(); | 81 | AssetBase asset = new AssetBase(); |
82 | DataRow row = ds.Tables["assets"].Rows.Find(uuid); | 82 | DataRow row = ds.Tables["assets"].Rows.Find(Util.ToRawUuidString(uuid)); |
83 | if (row != null) | 83 | if (row != null) |
84 | { | 84 | { |
85 | return buildAsset(row); | 85 | return buildAsset(row); |
@@ -103,7 +103,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
103 | DataTable assets = ds.Tables["assets"]; | 103 | DataTable assets = ds.Tables["assets"]; |
104 | lock (ds) | 104 | lock (ds) |
105 | { | 105 | { |
106 | DataRow row = assets.Rows.Find(asset.FullID); | 106 | DataRow row = assets.Rows.Find(Util.ToRawUuidString(asset.FullID)); |
107 | if (row == null) | 107 | if (row == null) |
108 | { | 108 | { |
109 | row = assets.NewRow(); | 109 | row = assets.NewRow(); |
@@ -130,7 +130,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
130 | 130 | ||
131 | public bool ExistsAsset(LLUUID uuid) | 131 | public bool ExistsAsset(LLUUID uuid) |
132 | { | 132 | { |
133 | DataRow row = ds.Tables["assets"].Rows.Find(uuid); | 133 | DataRow row = ds.Tables["assets"].Rows.Find(Util.ToRawUuidString(uuid)); |
134 | return (row != null); | 134 | return (row != null); |
135 | } | 135 | } |
136 | 136 | ||
@@ -138,7 +138,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
138 | { | 138 | { |
139 | lock (ds) | 139 | lock (ds) |
140 | { | 140 | { |
141 | DataRow row = ds.Tables["assets"].Rows.Find(uuid); | 141 | DataRow row = ds.Tables["assets"].Rows.Find(Util.ToRawUuidString(uuid)); |
142 | if (row != null) | 142 | if (row != null) |
143 | { | 143 | { |
144 | row.Delete(); | 144 | row.Delete(); |
@@ -210,7 +210,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
210 | 210 | ||
211 | private void fillAssetRow(DataRow row, AssetBase asset) | 211 | private void fillAssetRow(DataRow row, AssetBase asset) |
212 | { | 212 | { |
213 | row["UUID"] = asset.FullID; | 213 | row["UUID"] = Util.ToRawUuidString(asset.FullID); |
214 | row["Name"] = asset.Name; | 214 | row["Name"] = asset.Name; |
215 | if (asset.Description != null) | 215 | if (asset.Description != null) |
216 | { | 216 | { |
diff --git a/OpenSim/Framework/Data.SQLite/SQLiteGridData.cs b/OpenSim/Framework/Data.SQLite/SQLiteGridData.cs index dddc085..bb16a3e 100644 --- a/OpenSim/Framework/Data.SQLite/SQLiteGridData.cs +++ b/OpenSim/Framework/Data.SQLite/SQLiteGridData.cs | |||
@@ -119,7 +119,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
119 | public RegionProfileData GetProfileByLLUUID(LLUUID uuid) | 119 | public RegionProfileData GetProfileByLLUUID(LLUUID uuid) |
120 | { | 120 | { |
121 | Dictionary<string, string> param = new Dictionary<string, string>(); | 121 | Dictionary<string, string> param = new Dictionary<string, string>(); |
122 | param["uuid"] = uuid.ToString(); | 122 | param["uuid"] = Util.ToRawUuidString(uuid); |
123 | 123 | ||
124 | IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = @uuid", param); | 124 | IDbCommand result = database.Query("SELECT * FROM regions WHERE uuid = @uuid", param); |
125 | IDataReader reader = result.ExecuteReader(); | 125 | IDataReader reader = result.ExecuteReader(); |
@@ -190,7 +190,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
190 | SHA512Managed HashProvider = new SHA512Managed(); | 190 | SHA512Managed HashProvider = new SHA512Managed(); |
191 | ASCIIEncoding TextProvider = new ASCIIEncoding(); | 191 | ASCIIEncoding TextProvider = new ASCIIEncoding(); |
192 | 192 | ||
193 | byte[] stream = TextProvider.GetBytes(uuid.ToString() + ":" + handle.ToString() + ":" + challenge); | 193 | byte[] stream = TextProvider.GetBytes(Util.ToRawUuidString(uuid) + ":" + handle.ToString() + ":" + challenge); |
194 | byte[] hash = HashProvider.ComputeHash(stream); | 194 | byte[] hash = HashProvider.ComputeHash(stream); |
195 | 195 | ||
196 | return false; | 196 | return false; |
diff --git a/OpenSim/Framework/Data.SQLite/SQLiteUserData.cs b/OpenSim/Framework/Data.SQLite/SQLiteUserData.cs index 99121be..461cd08 100644 --- a/OpenSim/Framework/Data.SQLite/SQLiteUserData.cs +++ b/OpenSim/Framework/Data.SQLite/SQLiteUserData.cs | |||
@@ -77,11 +77,11 @@ namespace OpenSim.Framework.Data.SQLite | |||
77 | { | 77 | { |
78 | lock (ds) | 78 | lock (ds) |
79 | { | 79 | { |
80 | DataRow row = ds.Tables["users"].Rows.Find(uuid); | 80 | DataRow row = ds.Tables["users"].Rows.Find(Util.ToRawUuidString(uuid)); |
81 | if (row != null) | 81 | if (row != null) |
82 | { | 82 | { |
83 | UserProfileData user = buildUserProfile(row); | 83 | UserProfileData user = buildUserProfile(row); |
84 | row = ds.Tables["useragents"].Rows.Find(uuid); | 84 | row = ds.Tables["useragents"].Rows.Find(Util.ToRawUuidString(uuid)); |
85 | if (row != null) | 85 | if (row != null) |
86 | { | 86 | { |
87 | user.currentAgent = buildUserAgent(row); | 87 | user.currentAgent = buildUserAgent(row); |
@@ -105,7 +105,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
105 | if (rows.Length > 0) | 105 | if (rows.Length > 0) |
106 | { | 106 | { |
107 | UserProfileData user = buildUserProfile(rows[0]); | 107 | UserProfileData user = buildUserProfile(rows[0]); |
108 | DataRow row = ds.Tables["useragents"].Rows.Find(user.UUID); | 108 | DataRow row = ds.Tables["useragents"].Rows.Find(Util.ToRawUuidString(user.UUID)); |
109 | if (row != null) | 109 | if (row != null) |
110 | { | 110 | { |
111 | user.currentAgent = buildUserAgent(row); | 111 | user.currentAgent = buildUserAgent(row); |
@@ -220,7 +220,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
220 | DataTable users = ds.Tables["users"]; | 220 | DataTable users = ds.Tables["users"]; |
221 | lock (ds) | 221 | lock (ds) |
222 | { | 222 | { |
223 | DataRow row = users.Rows.Find(user.UUID); | 223 | DataRow row = users.Rows.Find(Util.ToRawUuidString(user.UUID)); |
224 | if (row == null) | 224 | if (row == null) |
225 | { | 225 | { |
226 | row = users.NewRow(); | 226 | row = users.NewRow(); |
@@ -238,7 +238,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
238 | if (user.currentAgent != null) | 238 | if (user.currentAgent != null) |
239 | { | 239 | { |
240 | DataTable ua = ds.Tables["useragents"]; | 240 | DataTable ua = ds.Tables["useragents"]; |
241 | row = ua.Rows.Find(user.UUID); | 241 | row = ua.Rows.Find(Util.ToRawUuidString(user.UUID)); |
242 | if (row == null) | 242 | if (row == null) |
243 | { | 243 | { |
244 | row = ua.NewRow(); | 244 | row = ua.NewRow(); |
@@ -255,7 +255,7 @@ namespace OpenSim.Framework.Data.SQLite | |||
255 | // I just added this to help the standalone login situation. | 255 | // I just added this to help the standalone login situation. |
256 | //It still needs to be looked at by a Database guy | 256 | //It still needs to be looked at by a Database guy |
257 | DataTable ua = ds.Tables["useragents"]; | 257 | DataTable ua = ds.Tables["useragents"]; |
258 | row = ua.Rows.Find(user.UUID); | 258 | row = ua.Rows.Find(Util.ToRawUuidString(user.UUID)); |
259 | 259 | ||
260 | if (row == null) | 260 | if (row == null) |
261 | { | 261 | { |