correction to last commit
authorCampbell Barton <ideasman42@gmail.com>
Wed, 25 Dec 2013 21:37:28 +0000 (08:37 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Wed, 25 Dec 2013 21:37:28 +0000 (08:37 +1100)
source/gameengine/Converter/BL_BlenderDataConversion.cpp

index a7d6fcbc0ed75347d232a36968e3830a505ffb5b..9dfad5bc0edd17adf8869cdb362186269bd32cc4 100644 (file)
@@ -941,7 +941,7 @@ RAS_MeshObject* BL_ConvertMesh(Mesh* mesh, Object* blenderobj, KX_Scene* scene,
 
        // Without checking names, we get some reuse we don't want that can cause
        // problems with material LoDs.
-       if ((meshobj = converter->FindGameMesh(mesh/*, ob->lay*/)) != NULL) {
+       if (blenderobj && ((meshobj = converter->FindGameMesh(mesh/*, ob->lay*/)) != NULL)) {
                const char *bge_name = meshobj->GetName().ReadPtr();
                const char *blender_name = ((ID *)blenderobj->data)->name + 2;
                if (STREQ(bge_name, blender_name)) {