diff options
author | Melanie Thielker | 2008-08-16 02:57:47 +0000 |
---|---|---|
committer | Melanie Thielker | 2008-08-16 02:57:47 +0000 |
commit | 9807a8639875aeb4a8594db3eda68009d96bba0c (patch) | |
tree | d6ddf4ac37e073d31c5df0519621c39129132ae3 | |
parent | Mantis#1890. Thank you kindly, Godfrey, for a patch that addresses: (diff) | |
download | opensim-SC_OLD-9807a8639875aeb4a8594db3eda68009d96bba0c.zip opensim-SC_OLD-9807a8639875aeb4a8594db3eda68009d96bba0c.tar.gz opensim-SC_OLD-9807a8639875aeb4a8594db3eda68009d96bba0c.tar.bz2 opensim-SC_OLD-9807a8639875aeb4a8594db3eda68009d96bba0c.tar.xz |
Guard against a null ref in the permissions module when a profile
fetch fails.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs index c181087..10f4897 100644 --- a/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs +++ b/OpenSim/Region/Environment/Modules/World/Permissions/PermissionsModule.cs | |||
@@ -247,8 +247,11 @@ namespace OpenSim.Region.Environment.Modules.World.Permissions | |||
247 | return true; | 247 | return true; |
248 | } | 248 | } |
249 | CachedUserInfo profile = m_scene.CommsManager.UserProfileCacheService.GetUserDetails(user); | 249 | CachedUserInfo profile = m_scene.CommsManager.UserProfileCacheService.GetUserDetails(user); |
250 | if(profile.UserProfile.GodLevel >= 200 && m_allowGridGods) | 250 | if(profile != null && profile.UserProfile != null) |
251 | return true; | 251 | { |
252 | if(profile.UserProfile.GodLevel >= 200 && m_allowGridGods) | ||
253 | return true; | ||
254 | } | ||
252 | 255 | ||
253 | return false; | 256 | return false; |
254 | } | 257 | } |