From 19d141c9a5848cbcc972b3e200ea0bff38f75b1a Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Thu, 11 May 2017 23:46:06 +0100 Subject: [PATCH] avoid a null ref --- OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs index cf96a8bbc1..5b3c3e68af 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs @@ -12569,11 +12569,11 @@ namespace OpenSim.Region.ClientStack.LindenUDP } int maxWearablesLoop = cachedtex.WearableData.Length; - if (maxWearablesLoop > cacheItems.Length) - maxWearablesLoop = cacheItems.Length; if (cacheItems != null) { + if (maxWearablesLoop > cacheItems.Length) + maxWearablesLoop = cacheItems.Length; for (int i = 0; i < maxWearablesLoop; i++) { int idx = cachedtex.WearableData[i].TextureIndex;