diff options
author | Sean Dague | 2009-06-29 15:05:12 +0000 |
---|---|---|
committer | Sean Dague | 2009-06-29 15:05:12 +0000 |
commit | 3dc2010da6412941bfbcdb29007b12a8f37b7bef (patch) | |
tree | f9fa0ad53b712d91d8fcc21aa6513c8a94dd4bf4 /OpenSim/Data/MySQL/MySQLRegionData.cs | |
parent | Thank you kindly, Godfrey, for a patch that: (diff) | |
download | opensim-SC_OLD-3dc2010da6412941bfbcdb29007b12a8f37b7bef.zip opensim-SC_OLD-3dc2010da6412941bfbcdb29007b12a8f37b7bef.tar.gz opensim-SC_OLD-3dc2010da6412941bfbcdb29007b12a8f37b7bef.tar.bz2 opensim-SC_OLD-3dc2010da6412941bfbcdb29007b12a8f37b7bef.tar.xz |
From: Chris Yeoh <yeohc@au1.ibm.com>
Attached is a patch that changes the oar file saving of creation date/time to an integer
instead of a string. I did this after justincc emailed me saying there is a problem
with internationalisation doing it the old way and I said I'd fix it. Its been
tested with MySQL and I've made the changes for MSSQL but that hasn't been well tested.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Data/MySQL/MySQLRegionData.cs | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/OpenSim/Data/MySQL/MySQLRegionData.cs b/OpenSim/Data/MySQL/MySQLRegionData.cs index 72c089e..a72ae45 100644 --- a/OpenSim/Data/MySQL/MySQLRegionData.cs +++ b/OpenSim/Data/MySQL/MySQLRegionData.cs | |||
@@ -741,7 +741,7 @@ namespace OpenSim.Data.MySQL | |||
741 | "terrain_raise_limit, terrain_lower_limit, " + | 741 | "terrain_raise_limit, terrain_lower_limit, " + |
742 | "use_estate_sun, fixed_sun, sun_position, " + | 742 | "use_estate_sun, fixed_sun, sun_position, " + |
743 | "covenant, Sandbox, sunvectorx, sunvectory, " + | 743 | "covenant, Sandbox, sunvectorx, sunvectory, " + |
744 | "sunvectorz, loaded_creation_date, loaded_creation_time, " + | 744 | "sunvectorz, loaded_creation_datetime, " + |
745 | "loaded_creation_id) values ( ?RegionUUID, ?BlockTerraform, " + | 745 | "loaded_creation_id) values ( ?RegionUUID, ?BlockTerraform, " + |
746 | "?BlockFly, ?AllowDamage, ?RestrictPushing, " + | 746 | "?BlockFly, ?AllowDamage, ?RestrictPushing, " + |
747 | "?AllowLandResell, ?AllowLandJoinDivide, " + | 747 | "?AllowLandResell, ?AllowLandJoinDivide, " + |
@@ -756,7 +756,7 @@ namespace OpenSim.Data.MySQL | |||
756 | "?TerrainLowerLimit, ?UseEstateSun, ?FixedSun, " + | 756 | "?TerrainLowerLimit, ?UseEstateSun, ?FixedSun, " + |
757 | "?SunPosition, ?Covenant, ?Sandbox, " + | 757 | "?SunPosition, ?Covenant, ?Sandbox, " + |
758 | "?SunVectorX, ?SunVectorY, ?SunVectorZ, " + | 758 | "?SunVectorX, ?SunVectorY, ?SunVectorZ, " + |
759 | "?LoadedCreationDate, ?LoadedCreationTime, ?LoadedCreationID)"; | 759 | "?LoadedCreationDateTime, ?LoadedCreationID)"; |
760 | 760 | ||
761 | FillRegionSettingsCommand(cmd, rs); | 761 | FillRegionSettingsCommand(cmd, rs); |
762 | 762 | ||
@@ -1042,15 +1042,7 @@ namespace OpenSim.Data.MySQL | |||
1042 | newSettings.SunPosition = Convert.ToDouble(row["sun_position"]); | 1042 | newSettings.SunPosition = Convert.ToDouble(row["sun_position"]); |
1043 | newSettings.Covenant = new UUID((String) row["covenant"]); | 1043 | newSettings.Covenant = new UUID((String) row["covenant"]); |
1044 | 1044 | ||
1045 | if (row["loaded_creation_date"] is DBNull) | 1045 | newSettings.LoadedCreationDateTime = Convert.ToInt32(row["loaded_creation_datetime"]); |
1046 | newSettings.LoadedCreationDate = ""; | ||
1047 | else | ||
1048 | newSettings.LoadedCreationDate = (String) row["loaded_creation_date"]; | ||
1049 | |||
1050 | if (row["loaded_creation_time"] is DBNull) | ||
1051 | newSettings.LoadedCreationTime = ""; | ||
1052 | else | ||
1053 | newSettings.LoadedCreationTime = (String) row["loaded_creation_time"]; | ||
1054 | 1046 | ||
1055 | if (row["loaded_creation_id"] is DBNull) | 1047 | if (row["loaded_creation_id"] is DBNull) |
1056 | newSettings.LoadedCreationID = ""; | 1048 | newSettings.LoadedCreationID = ""; |
@@ -1375,8 +1367,7 @@ namespace OpenSim.Data.MySQL | |||
1375 | cmd.Parameters.AddWithValue("FixedSun", settings.FixedSun); | 1367 | cmd.Parameters.AddWithValue("FixedSun", settings.FixedSun); |
1376 | cmd.Parameters.AddWithValue("SunPosition", settings.SunPosition); | 1368 | cmd.Parameters.AddWithValue("SunPosition", settings.SunPosition); |
1377 | cmd.Parameters.AddWithValue("Covenant", settings.Covenant.ToString()); | 1369 | cmd.Parameters.AddWithValue("Covenant", settings.Covenant.ToString()); |
1378 | cmd.Parameters.AddWithValue("LoadedCreationDate", settings.LoadedCreationDate); | 1370 | cmd.Parameters.AddWithValue("LoadedCreationDateTime", settings.LoadedCreationDate); |
1379 | cmd.Parameters.AddWithValue("LoadedCreationTime", settings.LoadedCreationTime); | ||
1380 | cmd.Parameters.AddWithValue("LoadedCreationID", settings.LoadedCreationID); | 1371 | cmd.Parameters.AddWithValue("LoadedCreationID", settings.LoadedCreationID); |
1381 | 1372 | ||
1382 | } | 1373 | } |