[Bf-blender-cvs] [844b40b0c17] master: Fix T56344: Crash when used Twist for Emitter type of Particles System.

Bastien Montagne noreply at git.blender.org
Mon Aug 13 11:58:00 CEST 2018


Commit: 844b40b0c174bbf5117b42427b0bc020a73bb60c
Author: Bastien Montagne
Date:   Mon Aug 13 11:57:18 2018 +0200
Branches: master
https://developer.blender.org/rB844b40b0c174bbf5117b42427b0bc020a73bb60c

Fix T56344: Crash when used Twist for Emitter type of Particles System.

That effect is NOP with emitter particles anyway...

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

M	source/blender/blenkernel/intern/particle_child.c

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

diff --git a/source/blender/blenkernel/intern/particle_child.c b/source/blender/blenkernel/intern/particle_child.c
index c921e1ea107..79c3f247232 100644
--- a/source/blender/blenkernel/intern/particle_child.c
+++ b/source/blender/blenkernel/intern/particle_child.c
@@ -737,6 +737,10 @@ static void do_twist(const ParticleChildModifierContext *modifier_ctx,
 	ParticleTexture *ptex = modifier_ctx->ptex;
 	ParticleSettings *part = sim->psys->part;
 	/* Early output checks. */
+	if (modifier_ctx->parent_keys == NULL) {
+		/* Cannot get axis of rotation... */
+		return;
+	}
 	if (part->childtype != PART_CHILD_PARTICLES) {
 		/* Interpolated children behave weird with twist. */
 		return;



More information about the Bf-blender-cvs mailing list