aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MySQL/MySQLAssetData.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Data/MySQL/MySQLAssetData.cs')
-rw-r--r--OpenSim/Data/MySQL/MySQLAssetData.cs10
1 files changed, 4 insertions, 6 deletions
diff --git a/OpenSim/Data/MySQL/MySQLAssetData.cs b/OpenSim/Data/MySQL/MySQLAssetData.cs
index f51eee2..3cda5b8 100644
--- a/OpenSim/Data/MySQL/MySQLAssetData.cs
+++ b/OpenSim/Data/MySQL/MySQLAssetData.cs
@@ -125,8 +125,7 @@ namespace OpenSim.Data.MySQL
125 new MySqlCommand( 125 new MySqlCommand(
126 "SELECT name, description, assetType, invType, local, temporary, data FROM assets WHERE id=?id", 126 "SELECT name, description, assetType, invType, local, temporary, data FROM assets WHERE id=?id",
127 _dbConnection.Connection); 127 _dbConnection.Connection);
128 MySqlParameter p = cmd.Parameters.Add("?id", MySqlDbType.Binary, 16); 128 cmd.Parameters.AddWithValue("?id", assetID.ToString());
129 p.Value = assetID.GetBytes();
130 129
131 try 130 try
132 { 131 {
@@ -180,8 +179,7 @@ namespace OpenSim.Data.MySQL
180 { 179 {
181 using (cmd) 180 using (cmd)
182 { 181 {
183 MySqlParameter p = cmd.Parameters.Add("?id", MySqlDbType.Binary, 16); 182 cmd.Parameters.AddWithValue("?id", asset.FullID.ToString());
184 p.Value = asset.FullID.GetBytes();
185 cmd.Parameters.AddWithValue("?name", asset.Name); 183 cmd.Parameters.AddWithValue("?name", asset.Name);
186 cmd.Parameters.AddWithValue("?description", asset.Description); 184 cmd.Parameters.AddWithValue("?description", asset.Description);
187 cmd.Parameters.AddWithValue("?assetType", asset.Type); 185 cmd.Parameters.AddWithValue("?assetType", asset.Type);
@@ -219,8 +217,8 @@ namespace OpenSim.Data.MySQL
219 new MySqlCommand( 217 new MySqlCommand(
220 "SELECT id FROM assets WHERE id=?id", 218 "SELECT id FROM assets WHERE id=?id",
221 _dbConnection.Connection); 219 _dbConnection.Connection);
222 MySqlParameter p = cmd.Parameters.Add("?id", MySqlDbType.Binary, 16); 220
223 p.Value = uuid.GetBytes(); 221 cmd.Parameters.AddWithValue("?id", uuid.ToString());
224 222
225 try 223 try
226 { 224 {