aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authormingchen2007-12-18 18:32:20 +0000
committermingchen2007-12-18 18:32:20 +0000
commit30b7c047fab84df0b8d6ea6b4da10a33429046b7 (patch)
tree863d7edfadf2ea0690238b92b9d8a4a7226ba42e
parent*Parcels and their access lists now store over multiple sessions when the dat... (diff)
downloadopensim-SC_OLD-30b7c047fab84df0b8d6ea6b4da10a33429046b7.zip
opensim-SC_OLD-30b7c047fab84df0b8d6ea6b4da10a33429046b7.tar.gz
opensim-SC_OLD-30b7c047fab84df0b8d6ea6b4da10a33429046b7.tar.bz2
opensim-SC_OLD-30b7c047fab84df0b8d6ea6b4da10a33429046b7.tar.xz
*Removed Unneeded Debug I added in my last revison
*Fixed typo causing access lists not to be stored correctly in sqlite
-rw-r--r--OpenSim/Region/Environment/LandManagement/LandManager.cs1
-rw-r--r--OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs6
2 files changed, 2 insertions, 5 deletions
diff --git a/OpenSim/Region/Environment/LandManagement/LandManager.cs b/OpenSim/Region/Environment/LandManagement/LandManager.cs
index 7904f12..f3ab502 100644
--- a/OpenSim/Region/Environment/LandManagement/LandManager.cs
+++ b/OpenSim/Region/Environment/LandManagement/LandManager.cs
@@ -104,6 +104,7 @@ namespace OpenSim.Region.Environment.LandManagement
104 } 104 }
105 105
106 #endregion 106 #endregion
107
107 #region Member Variables 108 #region Member Variables
108 109
109 public Dictionary<int, Land> landList = new Dictionary<int, Land>(); 110 public Dictionary<int, Land> landList = new Dictionary<int, Land>();
diff --git a/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs b/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
index cc9146d..6112720 100644
--- a/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
+++ b/OpenSim/Region/Storage/OpenSim.DataStore.MonoSqlite/MonoSqliteDataStore.cs
@@ -388,7 +388,6 @@ namespace OpenSim.DataStore.MonoSqlite
388 SqliteConnection conn = new SqliteConnection(m_connectionString); 388 SqliteConnection conn = new SqliteConnection(m_connectionString);
389 conn.Open(); 389 conn.Open();
390 390
391 Console.WriteLine("REMOVING LAND WITH ID " + globalID);
392 using (SqliteCommand cmd = new SqliteCommand("delete from land where UUID=:UUID", conn)) 391 using (SqliteCommand cmd = new SqliteCommand("delete from land where UUID=:UUID", conn))
393 { 392 {
394 cmd.Parameters.Add(new SqliteParameter(":UUID", globalID.ToString())); 393 cmd.Parameters.Add(new SqliteParameter(":UUID", globalID.ToString()));
@@ -410,8 +409,6 @@ namespace OpenSim.DataStore.MonoSqlite
410 { 409 {
411 SqliteConnection conn = new SqliteConnection(m_connectionString); 410 SqliteConnection conn = new SqliteConnection(m_connectionString);
412 conn.Open(); 411 conn.Open();
413
414 Console.WriteLine("STORING LAND TO SQLITE: " + parcel.landData.landName + " (" + parcel.landData.globalID + ")");
415 DataTable land = ds.Tables["land"]; 412 DataTable land = ds.Tables["land"];
416 DataTable landaccesslist = ds.Tables["landaccesslist"]; 413 DataTable landaccesslist = ds.Tables["landaccesslist"];
417 414
@@ -458,7 +455,6 @@ namespace OpenSim.DataStore.MonoSqlite
458 foreach (DataRow rawDataLand in rawDataForRegion) 455 foreach (DataRow rawDataLand in rawDataForRegion)
459 { 456 {
460 LandData newLand = buildLandData(rawDataLand); 457 LandData newLand = buildLandData(rawDataLand);
461 Console.WriteLine("LOADED NEW LAND FROM SQLITE: " + newLand.landName + " (" + newLand.globalID + ")");
462 string accessListSearchExp = "LandUUID = '" + newLand.globalID.ToString() + "'"; 458 string accessListSearchExp = "LandUUID = '" + newLand.globalID.ToString() + "'";
463 DataRow[] rawDataForLandAccessList = landaccesslist.Select(accessListSearchExp); 459 DataRow[] rawDataForLandAccessList = landaccesslist.Select(accessListSearchExp);
464 foreach (DataRow rawDataLandAccess in rawDataForLandAccessList) 460 foreach (DataRow rawDataLandAccess in rawDataForLandAccessList)
@@ -778,7 +774,7 @@ namespace OpenSim.DataStore.MonoSqlite
778 private ParcelManager.ParcelAccessEntry buildLandAccessData(DataRow row) 774 private ParcelManager.ParcelAccessEntry buildLandAccessData(DataRow row)
779 { 775 {
780 ParcelManager.ParcelAccessEntry entry = new ParcelManager.ParcelAccessEntry(); 776 ParcelManager.ParcelAccessEntry entry = new ParcelManager.ParcelAccessEntry();
781 entry.AgentID = new LLUUID((string)row["LandUUID"]); 777 entry.AgentID = new LLUUID((string)row["AccessUUID"]);
782 entry.Flags = (ParcelManager.AccessList)row["Flags"]; 778 entry.Flags = (ParcelManager.AccessList)row["Flags"];
783 entry.Time = new DateTime(); 779 entry.Time = new DateTime();
784 return entry; 780 return entry;