From 201c916670f9cd84347005523017049fb4275125 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Thu, 14 Dec 2017 05:36:15 +0000 Subject: add a missing return on a mesh decode error in ubOdemeshmerizer --- OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs') diff --git a/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs b/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs index a2a3f79..032d4ed 100644 --- a/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs +++ b/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs @@ -340,7 +340,7 @@ namespace OpenSim.Region.PhysicsModule.ubODEMeshing faces = new List(); OSD meshOsd = null; - if (primShape.SculptData.Length <= 0) + if (primShape.SculptData == null || primShape.SculptData.Length <= 0) { // m_log.InfoFormat("[MESH]: asset data for {0} is zero length", primName); return false; @@ -363,6 +363,7 @@ namespace OpenSim.Region.PhysicsModule.ubODEMeshing catch (Exception e) { m_log.Error("[MESH]: Exception deserializing mesh asset header:" + e.ToString()); + return false; } start = data.Position; -- cgit v1.1