[Bf-blender-cvs] [ef47b88] fracture_modifier: crash fix: removing the fracture modifier again from object without executing fracture first did crash

Martin Felke noreply at git.blender.org
Tue Feb 10 10:54:58 CET 2015


Commit: ef47b883cd4b2facc71933c5c6bc76289feba49f
Author: Martin Felke
Date:   Tue Feb 10 10:49:10 2015 +0100
Branches: fracture_modifier
https://developer.blender.org/rBef47b883cd4b2facc71933c5c6bc76289feba49f

crash fix: removing the fracture modifier again from object without executing fracture first did crash

===================================================================

M	source/blender/editors/object/object_modifier.c

===================================================================

diff --git a/source/blender/editors/object/object_modifier.c b/source/blender/editors/object/object_modifier.c
index feb9950..9868cb8 100644
--- a/source/blender/editors/object/object_modifier.c
+++ b/source/blender/editors/object/object_modifier.c
@@ -343,7 +343,10 @@ static bool object_modifier_remove(Main *bmain, Object *ob, ModifierData *md,
 	{
 		/* need to clean up modifier remainders inside the rigidbody world
 		 * AFTER the modifier is gone...  but only from the operator ?*/
-		BKE_rigidbody_rebuild_world(scene, -1);
+		if (scene->rigidbody_world)
+		{
+			BKE_rigidbody_rebuild_world(scene, -1);
+		}
 		BKE_scene_frame_set(scene, 1.0);
 	}




More information about the Bf-blender-cvs mailing list