Commit: 1c199401983bd53577cb180efe83ee5314f04296
Author: Campbell Barton
Date:   Tue Jun 21 09:41:25 2016 +1000
Branches: master
https://developer.blender.org/rB1c199401983bd53577cb180efe83ee5314f04296

Fix T48688: Crash loading particle effector weights

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

M       source/blender/blenloader/intern/readfile.c

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

diff --git a/source/blender/blenloader/intern/readfile.c 
b/source/blender/blenloader/intern/readfile.c
index b11f309..838179e 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -4054,9 +4054,13 @@ static void lib_link_particlesettings(FileData *fd, Main 
*main)
                        lib_link_partdeflect(fd, &part->id, part->pd);
                        lib_link_partdeflect(fd, &part->id, part->pd2);
                        
-                       if (part->effector_weights)
+                       if (part->effector_weights) {
                                part->effector_weights->group = newlibadr(fd, 
part->id.lib, part->effector_weights->group);
-                       
+                       }
+                       else {
+                               part->effector_weights = 
BKE_add_effector_weights(part->eff_group);
+                       }
+
                        if (part->dupliweights.first && part->dup_group) {
                                int index_ok = 0;
                                /* check for old files without indices (all 
indexes 0) */

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to