diff options
author | UbitUmarov | 2014-08-07 23:29:31 +0100 |
---|---|---|
committer | UbitUmarov | 2014-08-07 23:29:31 +0100 |
commit | 4ae0bb7df1774426ffa77898ac062a24bc6234f5 (patch) | |
tree | 5fa22dbe944bda41a5e88eef2696c106b454472f /OpenSim/Framework/ChildAgentDataUpdate.cs | |
parent | update the max number of texture faces and wearables to current values. (diff) | |
download | opensim-SC_OLD-4ae0bb7df1774426ffa77898ac062a24bc6234f5.zip opensim-SC_OLD-4ae0bb7df1774426ffa77898ac062a24bc6234f5.tar.gz opensim-SC_OLD-4ae0bb7df1774426ffa77898ac062a24bc6234f5.tar.bz2 opensim-SC_OLD-4ae0bb7df1774426ffa77898ac062a24bc6234f5.tar.xz |
add limites checks on wearables size, revert to max 15 for
compatibility/testing
Diffstat (limited to 'OpenSim/Framework/ChildAgentDataUpdate.cs')
-rw-r--r-- | OpenSim/Framework/ChildAgentDataUpdate.cs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/OpenSim/Framework/ChildAgentDataUpdate.cs b/OpenSim/Framework/ChildAgentDataUpdate.cs index 2a8e67d..5beb37d 100644 --- a/OpenSim/Framework/ChildAgentDataUpdate.cs +++ b/OpenSim/Framework/ChildAgentDataUpdate.cs | |||
@@ -665,7 +665,12 @@ namespace OpenSim.Framework | |||
665 | if ((args["wearables"] != null) && (args["wearables"]).Type == OSDType.Array) | 665 | if ((args["wearables"] != null) && (args["wearables"]).Type == OSDType.Array) |
666 | { | 666 | { |
667 | OSDArray wears = (OSDArray)(args["wearables"]); | 667 | OSDArray wears = (OSDArray)(args["wearables"]); |
668 | for (int i = 0; i < wears.Count / 2; i++) | 668 | |
669 | int count = wears.Count; | ||
670 | if (count > AvatarWearable.MAX_WEARABLES) | ||
671 | count = AvatarWearable.MAX_WEARABLES; | ||
672 | |||
673 | for (int i = 0; i < count / 2; i++) | ||
669 | { | 674 | { |
670 | AvatarWearable awear = new AvatarWearable((OSDArray)wears[i]); | 675 | AvatarWearable awear = new AvatarWearable((OSDArray)wears[i]); |
671 | Appearance.SetWearable(i,awear); | 676 | Appearance.SetWearable(i,awear); |