diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Data/MySQL/MySQLManager.cs | 10 | ||||
-rw-r--r-- | OpenSim/Data/MySQL/MySQLUserData.cs | 2 |
2 files changed, 9 insertions, 3 deletions
diff --git a/OpenSim/Data/MySQL/MySQLManager.cs b/OpenSim/Data/MySQL/MySQLManager.cs index 89d0672..297b1a7 100644 --- a/OpenSim/Data/MySQL/MySQLManager.cs +++ b/OpenSim/Data/MySQL/MySQLManager.cs | |||
@@ -538,6 +538,10 @@ namespace OpenSim.Data.MySQL | |||
538 | Convert.ToSingle(reader["homeLookAtY"].ToString()), | 538 | Convert.ToSingle(reader["homeLookAtY"].ToString()), |
539 | Convert.ToSingle(reader["homeLookAtZ"].ToString())); | 539 | Convert.ToSingle(reader["homeLookAtZ"].ToString())); |
540 | 540 | ||
541 | LLUUID regionID = LLUUID.Zero; | ||
542 | LLUUID.TryParse(reader["homeRegionID"].ToString(), out regionID); // it's ok if it doesn't work; just use LLUUID.Zero | ||
543 | retval.HomeRegionID = regionID; | ||
544 | |||
541 | retval.Created = Convert.ToInt32(reader["created"].ToString()); | 545 | retval.Created = Convert.ToInt32(reader["created"].ToString()); |
542 | retval.LastLogin = Convert.ToInt32(reader["lastLogin"].ToString()); | 546 | retval.LastLogin = Convert.ToInt32(reader["lastLogin"].ToString()); |
543 | 547 | ||
@@ -583,6 +587,7 @@ namespace OpenSim.Data.MySQL | |||
583 | LLUUID.TryParse((string)reader["webLoginKey"], out tmp); | 587 | LLUUID.TryParse((string)reader["webLoginKey"], out tmp); |
584 | retval.WebLoginKey = tmp; | 588 | retval.WebLoginKey = tmp; |
585 | } | 589 | } |
590 | |||
586 | } | 591 | } |
587 | else | 592 | else |
588 | { | 593 | { |
@@ -806,7 +811,7 @@ namespace OpenSim.Data.MySQL | |||
806 | /// <param name="webLoginKey">UUID for weblogin Key</param> | 811 | /// <param name="webLoginKey">UUID for weblogin Key</param> |
807 | /// <returns>Success?</returns> | 812 | /// <returns>Success?</returns> |
808 | public bool updateUserRow(LLUUID uuid, string username, string lastname, string passwordHash, | 813 | public bool updateUserRow(LLUUID uuid, string username, string lastname, string passwordHash, |
809 | string passwordSalt, UInt64 homeRegion, float homeLocX, float homeLocY, float homeLocZ, | 814 | string passwordSalt, UInt64 homeRegion, LLUUID homeRegionID, float homeLocX, float homeLocY, float homeLocZ, |
810 | float homeLookAtX, float homeLookAtY, float homeLookAtZ, int created, int lastlogin, | 815 | float homeLookAtX, float homeLookAtY, float homeLookAtZ, int created, int lastlogin, |
811 | string inventoryURI, string assetURI, uint canDoMask, uint wantDoMask, | 816 | string inventoryURI, string assetURI, uint canDoMask, uint wantDoMask, |
812 | string aboutText, string firstText, | 817 | string aboutText, string firstText, |
@@ -814,7 +819,7 @@ namespace OpenSim.Data.MySQL | |||
814 | { | 819 | { |
815 | string sql = "UPDATE users SET `username` = ?username , `lastname` = ?lastname "; | 820 | string sql = "UPDATE users SET `username` = ?username , `lastname` = ?lastname "; |
816 | sql += ", `passwordHash` = ?passwordHash , `passwordSalt` = ?passwordSalt , "; | 821 | sql += ", `passwordHash` = ?passwordHash , `passwordSalt` = ?passwordSalt , "; |
817 | sql += "`homeRegion` = ?homeRegion , `homeLocationX` = ?homeLocationX , "; | 822 | sql += "`homeRegion` = ?homeRegion , `homeRegionID` = ?homeRegionID, `homeLocationX` = ?homeLocationX , "; |
818 | sql += "`homeLocationY` = ?homeLocationY , `homeLocationZ` = ?homeLocationZ , "; | 823 | sql += "`homeLocationY` = ?homeLocationY , `homeLocationZ` = ?homeLocationZ , "; |
819 | sql += "`homeLookAtX` = ?homeLookAtX , `homeLookAtY` = ?homeLookAtY , "; | 824 | sql += "`homeLookAtX` = ?homeLookAtX , `homeLookAtY` = ?homeLookAtY , "; |
820 | sql += "`homeLookAtZ` = ?homeLookAtZ , `created` = ?created , `lastLogin` = ?lastLogin , "; | 825 | sql += "`homeLookAtZ` = ?homeLookAtZ , `created` = ?created , `lastLogin` = ?lastLogin , "; |
@@ -831,6 +836,7 @@ namespace OpenSim.Data.MySQL | |||
831 | parameters["?passwordHash"] = passwordHash.ToString(); | 836 | parameters["?passwordHash"] = passwordHash.ToString(); |
832 | parameters["?passwordSalt"] = passwordSalt.ToString(); | 837 | parameters["?passwordSalt"] = passwordSalt.ToString(); |
833 | parameters["?homeRegion"] = homeRegion.ToString(); | 838 | parameters["?homeRegion"] = homeRegion.ToString(); |
839 | parameters["?homeRegionID"] = homeRegionID.ToString(); | ||
834 | parameters["?homeLocationX"] = homeLocX.ToString(); | 840 | parameters["?homeLocationX"] = homeLocX.ToString(); |
835 | parameters["?homeLocationY"] = homeLocY.ToString(); | 841 | parameters["?homeLocationY"] = homeLocY.ToString(); |
836 | parameters["?homeLocationZ"] = homeLocZ.ToString(); | 842 | parameters["?homeLocationZ"] = homeLocZ.ToString(); |
diff --git a/OpenSim/Data/MySQL/MySQLUserData.cs b/OpenSim/Data/MySQL/MySQLUserData.cs index 131823a..d7bf2a8 100644 --- a/OpenSim/Data/MySQL/MySQLUserData.cs +++ b/OpenSim/Data/MySQL/MySQLUserData.cs | |||
@@ -682,7 +682,7 @@ namespace OpenSim.Data.MySQL | |||
682 | lock (database) | 682 | lock (database) |
683 | { | 683 | { |
684 | database.updateUserRow(user.ID, user.FirstName, user.SurName, user.PasswordHash, user.PasswordSalt, | 684 | database.updateUserRow(user.ID, user.FirstName, user.SurName, user.PasswordHash, user.PasswordSalt, |
685 | user.HomeRegion, user.HomeLocation.X, user.HomeLocation.Y, user.HomeLocation.Z, user.HomeLookAt.X, | 685 | user.HomeRegion, user.HomeRegionID, user.HomeLocation.X, user.HomeLocation.Y, user.HomeLocation.Z, user.HomeLookAt.X, |
686 | user.HomeLookAt.Y, user.HomeLookAt.Z, user.Created, user.LastLogin, user.UserInventoryURI, | 686 | user.HomeLookAt.Y, user.HomeLookAt.Z, user.Created, user.LastLogin, user.UserInventoryURI, |
687 | user.UserAssetURI, user.CanDoMask, user.WantDoMask, user.AboutText, | 687 | user.UserAssetURI, user.CanDoMask, user.WantDoMask, user.AboutText, |
688 | user.FirstLifeAboutText, user.Image, user.FirstLifeImage, user.WebLoginKey); | 688 | user.FirstLifeAboutText, user.Image, user.FirstLifeImage, user.WebLoginKey); |