aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Addons/Groups/Service/GroupsService.cs2
-rw-r--r--OpenSim/ApplicationPlugins/LoadRegions/RegionLoaderWebServer.cs2
-rw-r--r--OpenSim/Framework/Util.cs2
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs4
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs52
5 files changed, 42 insertions, 20 deletions
diff --git a/OpenSim/Addons/Groups/Service/GroupsService.cs b/OpenSim/Addons/Groups/Service/GroupsService.cs
index bed91d9..0792a47 100644
--- a/OpenSim/Addons/Groups/Service/GroupsService.cs
+++ b/OpenSim/Addons/Groups/Service/GroupsService.cs
@@ -492,7 +492,7 @@ namespace OpenSim.Groups
492 492
493 // check permissions 493 // check permissions
494 bool limited = HasPower(RequestingAgentID, GroupID, GroupPowers.AssignMemberLimited); 494 bool limited = HasPower(RequestingAgentID, GroupID, GroupPowers.AssignMemberLimited);
495 bool unlimited = HasPower(RequestingAgentID, GroupID, GroupPowers.AssignMember) | IsOwner(RequestingAgentID, GroupID); 495 bool unlimited = HasPower(RequestingAgentID, GroupID, GroupPowers.AssignMember) || IsOwner(RequestingAgentID, GroupID);
496 if (!limited && !unlimited) 496 if (!limited && !unlimited)
497 { 497 {
498 m_log.DebugFormat("[Groups]: ({0}) Attempt at assigning {1} to role {2} denied because of lack of permission", RequestingAgentID, AgentID, RoleID); 498 m_log.DebugFormat("[Groups]: ({0}) Attempt at assigning {1} to role {2} denied because of lack of permission", RequestingAgentID, AgentID, RoleID);
diff --git a/OpenSim/ApplicationPlugins/LoadRegions/RegionLoaderWebServer.cs b/OpenSim/ApplicationPlugins/LoadRegions/RegionLoaderWebServer.cs
index 13d7a8a..2cfd493 100644
--- a/OpenSim/ApplicationPlugins/LoadRegions/RegionLoaderWebServer.cs
+++ b/OpenSim/ApplicationPlugins/LoadRegions/RegionLoaderWebServer.cs
@@ -122,7 +122,7 @@ namespace OpenSim.ApplicationPlugins.LoadRegions
122 throw ex; 122 throw ex;
123 } 123 }
124 124
125 if (regionCount > 0 | allowRegionless) 125 if (regionCount > 0 || allowRegionless)
126 return regionInfos; 126 return regionInfos;
127 127
128 m_log.Debug("[WEBLOADER]: Request yielded no regions."); 128 m_log.Debug("[WEBLOADER]: Request yielded no regions.");
diff --git a/OpenSim/Framework/Util.cs b/OpenSim/Framework/Util.cs
index 6e0d30d..f8469b6 100644
--- a/OpenSim/Framework/Util.cs
+++ b/OpenSim/Framework/Util.cs
@@ -899,7 +899,7 @@ namespace OpenSim.Framework
899 /// <returns></returns> 899 /// <returns></returns>
900 public static bool IsInsideBox(Vector3 v, Vector3 min, Vector3 max) 900 public static bool IsInsideBox(Vector3 v, Vector3 min, Vector3 max)
901 { 901 {
902 return v.X >= min.X & v.Y >= min.Y && v.Z >= min.Z 902 return v.X >= min.X && v.Y >= min.Y && v.Z >= min.Z
903 && v.X <= max.X && v.Y <= max.Y && v.Z <= max.Z; 903 && v.X <= max.X && v.Y <= max.Y && v.Z <= max.Z;
904 } 904 }
905 905
diff --git a/OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs b/OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs
index 5d7f25c..abeed5b 100644
--- a/OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Inventory/Transfer/InventoryTransferModule.cs
@@ -396,7 +396,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Transfer
396 { 396 {
397 folder = invService.GetFolder(client.AgentId, inventoryID); 397 folder = invService.GetFolder(client.AgentId, inventoryID);
398 398
399 if (folder != null & trashFolder != null) 399 if (folder != null && trashFolder != null)
400 { 400 {
401 previousParentFolderID = folder.ParentID; 401 previousParentFolderID = folder.ParentID;
402 folder.ParentID = trashFolder.ID; 402 folder.ParentID = trashFolder.ID;
@@ -405,7 +405,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Transfer
405 } 405 }
406 } 406 }
407 407
408 if ((null == item && null == folder) | null == trashFolder) 408 if ((null == item && null == folder) || null == trashFolder)
409 { 409 {
410 string reason = String.Empty; 410 string reason = String.Empty;
411 411
diff --git a/OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs b/OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs
index e9ee937..0331a4c 100644
--- a/OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/LSL_Types.cs
@@ -84,16 +84,26 @@ namespace OpenSim.Region.ScriptEngine.Shared
84 { 84 {
85 str = str.Replace('<', ' '); 85 str = str.Replace('<', ' ');
86 str = str.Replace('>', ' '); 86 str = str.Replace('>', ' ');
87 string[] tmps = str.Split(new Char[] { ',', '<', '>' }); 87 string[] tmps = str.Split(new Char[] {','});
88 if (tmps.Length < 3) 88 if (tmps.Length < 3)
89 { 89 {
90 x=y=z=0; 90 z = y = x = 0;
91 return; 91 return;
92 } 92 }
93 bool res; 93 if (!Double.TryParse(tmps[0], NumberStyles.Float, Culture.NumberFormatInfo, out x))
94 res = Double.TryParse(tmps[0], NumberStyles.Float, Culture.NumberFormatInfo, out x); 94 {
95 res = res & Double.TryParse(tmps[1], NumberStyles.Float, Culture.NumberFormatInfo, out y); 95 z = y = 0;
96 res = res & Double.TryParse(tmps[2], NumberStyles.Float, Culture.NumberFormatInfo, out z); 96 return;
97 }
98 if (!Double.TryParse(tmps[1], NumberStyles.Float, Culture.NumberFormatInfo, out y))
99 {
100 z = x = 0;
101 return;
102 }
103 if (!Double.TryParse(tmps[2], NumberStyles.Float, Culture.NumberFormatInfo, out z))
104 {
105 y = x = 0;
106 }
97 } 107 }
98 108
99 #endregion 109 #endregion
@@ -364,19 +374,31 @@ namespace OpenSim.Region.ScriptEngine.Shared
364 { 374 {
365 str = str.Replace('<', ' '); 375 str = str.Replace('<', ' ');
366 str = str.Replace('>', ' '); 376 str = str.Replace('>', ' ');
367 string[] tmps = str.Split(new Char[] { ',', '<', '>' }); 377 string[] tmps = str.Split(new Char[] {','});
368 if (tmps.Length < 4) 378 if (tmps.Length < 4 ||
379 !Double.TryParse(tmps[3], NumberStyles.Float, Culture.NumberFormatInfo, out s))
369 { 380 {
370 x=y=z=s=0; 381 z = y = x = 0;
382 s = 1;
371 return; 383 return;
372 } 384 }
373 bool res; 385 if (!Double.TryParse(tmps[0], NumberStyles.Float, Culture.NumberFormatInfo, out x))
374 res = Double.TryParse(tmps[0], NumberStyles.Float, Culture.NumberFormatInfo, out x); 386 {
375 res = res & Double.TryParse(tmps[1], NumberStyles.Float, Culture.NumberFormatInfo, out y); 387 z = y = 0;
376 res = res & Double.TryParse(tmps[2], NumberStyles.Float, Culture.NumberFormatInfo, out z); 388 s = 1;
377 res = res & Double.TryParse(tmps[3], NumberStyles.Float, Culture.NumberFormatInfo, out s); 389 return;
378 if (s == 0 && x == 0 && y == 0 && z == 0) 390 }
391 if (!Double.TryParse(tmps[1], NumberStyles.Float, Culture.NumberFormatInfo, out y))
392 {
393 z = x = 0;
379 s = 1; 394 s = 1;
395 return;
396 }
397 if (!Double.TryParse(tmps[2], NumberStyles.Float, Culture.NumberFormatInfo, out z))
398 {
399 y = x = 0;
400 s = 1;
401 }
380 } 402 }
381 403
382 public Quaternion(OMV_Quaternion rot) 404 public Quaternion(OMV_Quaternion rot)