aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules/World/Permissions
diff options
context:
space:
mode:
authorJeff Ames2009-06-09 18:07:35 +0000
committerJeff Ames2009-06-09 18:07:35 +0000
commita7fcacf8f396acbca0b640a65acfbf5487d513e7 (patch)
tree5ba66f5c83eceeb81e24a0540ae4fac9847e0c78 /OpenSim/Region/CoreModules/World/Permissions
parentUpdate svn properties. (diff)
downloadopensim-SC-a7fcacf8f396acbca0b640a65acfbf5487d513e7.zip
opensim-SC-a7fcacf8f396acbca0b640a65acfbf5487d513e7.tar.gz
opensim-SC-a7fcacf8f396acbca0b640a65acfbf5487d513e7.tar.bz2
opensim-SC-a7fcacf8f396acbca0b640a65acfbf5487d513e7.tar.xz
Formatting cleanup. Ignore some generated files.
Diffstat (limited to 'OpenSim/Region/CoreModules/World/Permissions')
-rw-r--r--OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs38
1 files changed, 19 insertions, 19 deletions
diff --git a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs
index 036c4b8..d786df8 100644
--- a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs
+++ b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs
@@ -243,7 +243,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
243 243
244 244
245 string grant = myConfig.GetString("GrantLSL",""); 245 string grant = myConfig.GetString("GrantLSL","");
246 if(grant.Length > 0) { 246 if (grant.Length > 0) {
247 foreach (string uuidl in grant.Split(',')) { 247 foreach (string uuidl in grant.Split(',')) {
248 string uuid = uuidl.Trim(" \t".ToCharArray()); 248 string uuid = uuidl.Trim(" \t".ToCharArray());
249 GrantLSL.Add(uuid, true); 249 GrantLSL.Add(uuid, true);
@@ -251,7 +251,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
251 } 251 }
252 252
253 grant = myConfig.GetString("GrantCS",""); 253 grant = myConfig.GetString("GrantCS","");
254 if(grant.Length > 0) { 254 if (grant.Length > 0) {
255 foreach (string uuidl in grant.Split(',')) { 255 foreach (string uuidl in grant.Split(',')) {
256 string uuid = uuidl.Trim(" \t".ToCharArray()); 256 string uuid = uuidl.Trim(" \t".ToCharArray());
257 GrantCS.Add(uuid, true); 257 GrantCS.Add(uuid, true);
@@ -259,7 +259,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
259 } 259 }
260 260
261 grant = myConfig.GetString("GrantVB",""); 261 grant = myConfig.GetString("GrantVB","");
262 if(grant.Length > 0) { 262 if (grant.Length > 0) {
263 foreach (string uuidl in grant.Split(',')) { 263 foreach (string uuidl in grant.Split(',')) {
264 string uuid = uuidl.Trim(" \t".ToCharArray()); 264 string uuid = uuidl.Trim(" \t".ToCharArray());
265 GrantVB.Add(uuid, true); 265 GrantVB.Add(uuid, true);
@@ -267,7 +267,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
267 } 267 }
268 268
269 grant = myConfig.GetString("GrantJS",""); 269 grant = myConfig.GetString("GrantJS","");
270 if(grant.Length > 0) { 270 if (grant.Length > 0) {
271 foreach (string uuidl in grant.Split(',')) { 271 foreach (string uuidl in grant.Split(',')) {
272 string uuid = uuidl.Trim(" \t".ToCharArray()); 272 string uuid = uuidl.Trim(" \t".ToCharArray());
273 GrantJS.Add(uuid, true); 273 GrantJS.Add(uuid, true);
@@ -563,7 +563,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
563 } 563 }
564 564
565 // Group permissions 565 // Group permissions
566 if ( ( task.GroupID != UUID.Zero) && IsGroupMember(task.GroupID, user, 0) ) 566 if ((task.GroupID != UUID.Zero) && IsGroupMember(task.GroupID, user, 0))
567 return objectGroupMask; 567 return objectGroupMask;
568 568
569 return objectEveryoneMask; 569 return objectEveryoneMask;
@@ -650,7 +650,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
650 } 650 }
651 651
652 // Group members should be able to edit group objects 652 // Group members should be able to edit group objects
653 if ( (group.GroupID != UUID.Zero) && ((m_scene.GetSceneObjectPart(objId).GroupMask & (uint)PermissionMask.Modify) != 0) && IsGroupMember(group.GroupID, currentUser, 0) ) 653 if ((group.GroupID != UUID.Zero) && ((m_scene.GetSceneObjectPart(objId).GroupMask & (uint)PermissionMask.Modify) != 0) && IsGroupMember(group.GroupID, currentUser, 0))
654 { 654 {
655 // Return immediately, so that the administrator can shares group objects 655 // Return immediately, so that the administrator can shares group objects
656 return true; 656 return true;
@@ -731,7 +731,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
731 permission = true; 731 permission = true;
732 } 732 }
733 733
734 if( ( parcel.landData.GroupID != UUID.Zero) && IsGroupMember(parcel.landData.GroupID, user, groupPowers) ) 734 if ((parcel.landData.GroupID != UUID.Zero) && IsGroupMember(parcel.landData.GroupID, user, groupPowers))
735 { 735 {
736 permission = true; 736 permission = true;
737 } 737 }
@@ -758,7 +758,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
758 permission = true; 758 permission = true;
759 } 759 }
760 760
761 if( parcel.landData.IsGroupOwned && IsGroupMember(parcel.landData.GroupID, user, groupPowers) ) 761 if (parcel.landData.IsGroupOwned && IsGroupMember(parcel.landData.GroupID, user, groupPowers))
762 { 762 {
763 permission = true; 763 permission = true;
764 } 764 }
@@ -982,7 +982,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
982 if (part.GroupID == UUID.Zero) 982 if (part.GroupID == UUID.Zero)
983 return false; 983 return false;
984 984
985 if( !IsGroupMember(part.GroupID, user, 0) ) 985 if (!IsGroupMember(part.GroupID, user, 0))
986 return false; 986 return false;
987 987
988 if ((part.GroupMask & (uint)PermissionMask.Modify) == 0) 988 if ((part.GroupMask & (uint)PermissionMask.Modify) == 0)
@@ -1002,7 +1002,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
1002 if (ti.GroupID == UUID.Zero) 1002 if (ti.GroupID == UUID.Zero)
1003 return false; 1003 return false;
1004 1004
1005 if( !IsGroupMember(ti.GroupID, user, 0) ) 1005 if (!IsGroupMember(ti.GroupID, user, 0))
1006 return false; 1006 return false;
1007 } 1007 }
1008 1008
@@ -1411,7 +1411,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
1411 if (part.GroupID == UUID.Zero) 1411 if (part.GroupID == UUID.Zero)
1412 return false; 1412 return false;
1413 1413
1414 if( !IsGroupMember(part.GroupID, user, 0) ) 1414 if (!IsGroupMember(part.GroupID, user, 0))
1415 return false; 1415 return false;
1416 1416
1417 if ((part.GroupMask & (uint)PermissionMask.Modify) == 0) 1417 if ((part.GroupMask & (uint)PermissionMask.Modify) == 0)
@@ -1431,7 +1431,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
1431 if (ti.GroupID == UUID.Zero) 1431 if (ti.GroupID == UUID.Zero)
1432 return false; 1432 return false;
1433 1433
1434 if( !IsGroupMember(ti.GroupID, user, 0) ) 1434 if (!IsGroupMember(ti.GroupID, user, 0))
1435 return false; 1435 return false;
1436 } 1436 }
1437 1437
@@ -1504,7 +1504,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
1504 if (part.GroupID == UUID.Zero) 1504 if (part.GroupID == UUID.Zero)
1505 return false; 1505 return false;
1506 1506
1507 if( !IsGroupMember(part.GroupID, user, 0) ) 1507 if (!IsGroupMember(part.GroupID, user, 0))
1508 return false; 1508 return false;
1509 } 1509 }
1510 1510
@@ -1521,7 +1521,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
1521 if (ti.GroupID == UUID.Zero) 1521 if (ti.GroupID == UUID.Zero)
1522 return false; 1522 return false;
1523 1523
1524 if( !IsGroupMember(ti.GroupID, user, 0) ) 1524 if (!IsGroupMember(ti.GroupID, user, 0))
1525 return false; 1525 return false;
1526 } 1526 }
1527 1527
@@ -1744,24 +1744,24 @@ namespace OpenSim.Region.CoreModules.World.Permissions
1744 1744
1745 private bool CanCompileScript(UUID ownerUUID, int scriptType, Scene scene) { 1745 private bool CanCompileScript(UUID ownerUUID, int scriptType, Scene scene) {
1746 //m_log.DebugFormat("check if {0} is allowed to compile {1}", ownerUUID, scriptType); 1746 //m_log.DebugFormat("check if {0} is allowed to compile {1}", ownerUUID, scriptType);
1747 switch(scriptType) { 1747 switch (scriptType) {
1748 case 0: 1748 case 0:
1749 if(GrantLSL.Count == 0 || GrantLSL.ContainsKey(ownerUUID.ToString())) { 1749 if (GrantLSL.Count == 0 || GrantLSL.ContainsKey(ownerUUID.ToString())) {
1750 return(true); 1750 return(true);
1751 } 1751 }
1752 break; 1752 break;
1753 case 1: 1753 case 1:
1754 if(GrantCS.Count == 0 || GrantCS.ContainsKey(ownerUUID.ToString())) { 1754 if (GrantCS.Count == 0 || GrantCS.ContainsKey(ownerUUID.ToString())) {
1755 return(true); 1755 return(true);
1756 } 1756 }
1757 break; 1757 break;
1758 case 2: 1758 case 2:
1759 if(GrantVB.Count == 0 || GrantVB.ContainsKey(ownerUUID.ToString())) { 1759 if (GrantVB.Count == 0 || GrantVB.ContainsKey(ownerUUID.ToString())) {
1760 return(true); 1760 return(true);
1761 } 1761 }
1762 break; 1762 break;
1763 case 3: 1763 case 3:
1764 if(GrantJS.Count == 0 || GrantJS.ContainsKey(ownerUUID.ToString())) { 1764 if (GrantJS.Count == 0 || GrantJS.ContainsKey(ownerUUID.ToString())) {
1765 return(true); 1765 return(true);
1766 } 1766 }
1767 break; 1767 break;