From e4d25da6989fe361202efce9b371782aef809bac Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sun, 6 Apr 2008 20:13:14 +0000 Subject: [PATCH] fix for [#6342] Collada 1.4 import (of perhaps corrupt collada files) leads to a complete crash of Blender 2.43 under Windows XP NMesh wasnt checking 16max material limit, also made collada import work with the user scripts dir. --- source/blender/python/api2_2x/NMesh.c | 1 + 1 file changed, 1 insertion(+) diff --git a/source/blender/python/api2_2x/NMesh.c b/source/blender/python/api2_2x/NMesh.c index 4fb95ecd9eb..983f06ed2fc 100644 --- a/source/blender/python/api2_2x/NMesh.c +++ b/source/blender/python/api2_2x/NMesh.c @@ -2730,6 +2730,7 @@ Material **nmesh_updateMaterials( BPy_NMesh * nmesh ) } if( len > 0 ) { + if (len>16) len = 16; matlist = EXPP_newMaterialList_fromPyList( nmesh->materials ); EXPP_incr_mats_us( matlist, len );