aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/SQLite/SQLiteRegionData.cs
diff options
context:
space:
mode:
authorTeravus Ovares2008-06-20 17:07:01 +0000
committerTeravus Ovares2008-06-20 17:07:01 +0000
commitf8b17854676eafab64712a2bbde3de696719a603 (patch)
treea347fe0a25b4032fc100cfc55944691b5466f94e /OpenSim/Data/SQLite/SQLiteRegionData.cs
parentUpdate OS X ODE binary to opensim-libs r46. (diff)
downloadopensim-SC_OLD-f8b17854676eafab64712a2bbde3de696719a603.zip
opensim-SC_OLD-f8b17854676eafab64712a2bbde3de696719a603.tar.gz
opensim-SC_OLD-f8b17854676eafab64712a2bbde3de696719a603.tar.bz2
opensim-SC_OLD-f8b17854676eafab64712a2bbde3de696719a603.tar.xz
* Handle parcel telehub location corruption gracefully. DBNull
Diffstat (limited to '')
-rw-r--r--OpenSim/Data/SQLite/SQLiteRegionData.cs21
1 files changed, 15 insertions, 6 deletions
diff --git a/OpenSim/Data/SQLite/SQLiteRegionData.cs b/OpenSim/Data/SQLite/SQLiteRegionData.cs
index cc059af..36202b9 100644
--- a/OpenSim/Data/SQLite/SQLiteRegionData.cs
+++ b/OpenSim/Data/SQLite/SQLiteRegionData.cs
@@ -972,13 +972,22 @@ namespace OpenSim.Data.SQLite
972 newData.passHours = Convert.ToSingle(row["PassHours"]); 972 newData.passHours = Convert.ToSingle(row["PassHours"]);
973 newData.passPrice = Convert.ToInt32(row["PassPrice"]); 973 newData.passPrice = Convert.ToInt32(row["PassPrice"]);
974 newData.snapshotID = (String) row["SnapshotUUID"]; 974 newData.snapshotID = (String) row["SnapshotUUID"];
975 try
976 {
975 977
976 newData.userLocation = 978 newData.userLocation =
977 new LLVector3(Convert.ToSingle(row["UserLocationX"]), Convert.ToSingle(row["UserLocationY"]), 979 new LLVector3(Convert.ToSingle(row["UserLocationX"]), Convert.ToSingle(row["UserLocationY"]),
978 Convert.ToSingle(row["UserLocationZ"])); 980 Convert.ToSingle(row["UserLocationZ"]));
979 newData.userLookAt = 981 newData.userLookAt =
980 new LLVector3(Convert.ToSingle(row["UserLookAtX"]), Convert.ToSingle(row["UserLookAtY"]), 982 new LLVector3(Convert.ToSingle(row["UserLookAtX"]), Convert.ToSingle(row["UserLookAtY"]),
981 Convert.ToSingle(row["UserLookAtZ"])); 983 Convert.ToSingle(row["UserLookAtZ"]));
984 m_log.ErrorFormat("[PARCEL]: unable to get parcel telehub settings for {1}", newData.landName);
985 }
986 catch (InvalidCastException)
987 {
988 newData.userLocation = LLVector3.Zero;
989 newData.userLookAt = LLVector3.Zero;
990 }
982 newData.parcelAccessList = new List<ParcelManager.ParcelAccessEntry>(); 991 newData.parcelAccessList = new List<ParcelManager.ParcelAccessEntry>();
983 LLUUID authBuyerID = LLUUID.Zero; 992 LLUUID authBuyerID = LLUUID.Zero;
984 993