Merging r42621 through r42647 from trunk into soc-2011-tomato
[blender.git] / source / blender / blenloader / intern / readfile.c
index 340582ba6276e6423e2537fcd76d9af960f5760f..c8130ba6f244f4e3301a6ccb4402584995ed5e0f 100644 (file)
@@ -8746,9 +8746,9 @@ static void do_versions(FileData *fd, Library *lib, Main *main)
                        }
                        if(ob->soft && ob->soft->vertgroup==0) {
                                bDeformGroup *locGroup = defgroup_find_name(ob, "SOFTGOAL");
                        }
                        if(ob->soft && ob->soft->vertgroup==0) {
                                bDeformGroup *locGroup = defgroup_find_name(ob, "SOFTGOAL");
-                               if(locGroup){
+                               if (locGroup) {
                                        /* retrieve index for that group */
                                        /* retrieve index for that group */
-                                       ob->soft->vertgroup =  1 + defgroup_find_index(ob, locGroup); 
+                                       ob->soft->vertgroup =  1 + BLI_findindex(&ob->defbase, locGroup);
                                }
                        }
                }
                                }
                        }
                }