aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Modules
diff options
context:
space:
mode:
authorJustin Clarke Casey2008-10-15 16:35:27 +0000
committerJustin Clarke Casey2008-10-15 16:35:27 +0000
commit9324c3f110d70d44ef91c18e570cffc59d067683 (patch)
tree6ce60aa08beca59e9e985868f7435ed89cabf59d /OpenSim/Region/Environment/Modules
parent* minor: oops, small textual tweak (diff)
downloadopensim-SC-9324c3f110d70d44ef91c18e570cffc59d067683.zip
opensim-SC-9324c3f110d70d44ef91c18e570cffc59d067683.tar.gz
opensim-SC-9324c3f110d70d44ef91c18e570cffc59d067683.tar.bz2
opensim-SC-9324c3f110d70d44ef91c18e570cffc59d067683.tar.xz
* refactor: Move error logging from GetUserDetails up to callers, since there are some circumstances in which not finding a user is not an error
Diffstat (limited to 'OpenSim/Region/Environment/Modules')
-rw-r--r--OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetXferUploader.cs12
-rw-r--r--OpenSim/Region/Environment/Modules/Avatar/Currency/SampleMoney/SampleMoneyModule.cs7
-rw-r--r--OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs17
3 files changed, 36 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetXferUploader.cs b/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetXferUploader.cs
index 5484ad5..2763831 100644
--- a/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetXferUploader.cs
+++ b/OpenSim/Region/Environment/Modules/Agent/AssetTransaction/AssetXferUploader.cs
@@ -244,6 +244,12 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction
244 244
245 userInfo.UpdateItem(item); 245 userInfo.UpdateItem(item);
246 } 246 }
247 else
248 {
249 m_log.ErrorFormat(
250 "[ASSET TRANSACTIONS]: Could not find user {0} for inventory item update",
251 remoteClient.AgentId);
252 }
247 } 253 }
248 } 254 }
249 255
@@ -294,6 +300,12 @@ namespace OpenSim.Region.Environment.Modules.Agent.AssetTransaction
294 userInfo.AddItem(item); 300 userInfo.AddItem(item);
295 ourClient.SendInventoryItemCreateUpdate(item); 301 ourClient.SendInventoryItemCreateUpdate(item);
296 } 302 }
303 else
304 {
305 m_log.ErrorFormat(
306 "[ASSET TRANSACTIONS]: Could not find user {0} for inventory item creation",
307 ourClient.AgentId);
308 }
297 } 309 }
298 310
299 /// <summary> 311 /// <summary>
diff --git a/OpenSim/Region/Environment/Modules/Avatar/Currency/SampleMoney/SampleMoneyModule.cs b/OpenSim/Region/Environment/Modules/Avatar/Currency/SampleMoney/SampleMoneyModule.cs
index a015c63..1f57fb5 100644
--- a/OpenSim/Region/Environment/Modules/Avatar/Currency/SampleMoney/SampleMoneyModule.cs
+++ b/OpenSim/Region/Environment/Modules/Avatar/Currency/SampleMoney/SampleMoneyModule.cs
@@ -604,6 +604,13 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Currency.SampleMoney
604 string avatarname = profile.UserProfile.FirstName + " " + profile.UserProfile.SurName; 604 string avatarname = profile.UserProfile.FirstName + " " + profile.UserProfile.SurName;
605 return avatarname; 605 return avatarname;
606 } 606 }
607 else
608 {
609 m_log.ErrorFormat(
610 "[MONEY]: Could not resolve user {0}",
611 agentID);
612 }
613
607 return String.Empty; 614 return String.Empty;
608 } 615 }
609 616
diff --git a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs
index abbf40e..b6a0c23 100644
--- a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs
+++ b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs
@@ -259,6 +259,10 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions
259 if (profile.UserProfile.GodLevel >= 200) 259 if (profile.UserProfile.GodLevel >= 200)
260 return true; 260 return true;
261 } 261 }
262 else
263 {
264 m_log.ErrorFormat("[PERMISSIONS]: Could not find user {0} for administrator check", user);
265 }
262 } 266 }
263 267
264 return false; 268 return false;
@@ -646,8 +650,13 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions
646 { 650 {
647 CachedUserInfo userInfo = 651 CachedUserInfo userInfo =
648 scene.CommsManager.UserProfileCacheService.GetUserDetails(user); 652 scene.CommsManager.UserProfileCacheService.GetUserDetails(user);
653
649 if (userInfo == null) 654 if (userInfo == null)
655 {
656 m_log.ErrorFormat("[PERMISSIONS]: Could not find user {0} for edit notecard check", user);
650 return false; 657 return false;
658 }
659
651 660
652 if (userInfo.RootFolder == null) 661 if (userInfo.RootFolder == null)
653 return false; 662 return false;
@@ -1024,8 +1033,12 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions
1024 { 1033 {
1025 CachedUserInfo userInfo = 1034 CachedUserInfo userInfo =
1026 scene.CommsManager.UserProfileCacheService.GetUserDetails(user); 1035 scene.CommsManager.UserProfileCacheService.GetUserDetails(user);
1036
1027 if (userInfo == null) 1037 if (userInfo == null)
1038 {
1039 m_log.ErrorFormat("[PERMISSIONS]: Could not find user {0} for administrator check", user);
1028 return false; 1040 return false;
1041 }
1029 1042
1030 if (userInfo.RootFolder == null) 1043 if (userInfo.RootFolder == null)
1031 return false; 1044 return false;
@@ -1102,8 +1115,12 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions
1102 { 1115 {
1103 CachedUserInfo userInfo = 1116 CachedUserInfo userInfo =
1104 scene.CommsManager.UserProfileCacheService.GetUserDetails(user); 1117 scene.CommsManager.UserProfileCacheService.GetUserDetails(user);
1118
1105 if (userInfo == null) 1119 if (userInfo == null)
1120 {
1121 m_log.ErrorFormat("[PERMISSIONS]: Could not find user {0} for view notecard check", user);
1106 return false; 1122 return false;
1123 }
1107 1124
1108 if (userInfo.RootFolder == null) 1125 if (userInfo.RootFolder == null)
1109 return false; 1126 return false;