Wednesday merger of Orange branch and bf-blender
[blender-staging.git] / source / blender / blenkernel / intern / action.c
index 38a07f246dcb4b811b31815a818a0891827df0da..d6bca577013e609949527973e40a742e07bb4fad 100644 (file)
@@ -204,7 +204,7 @@ bPoseChannel *verify_pose_channel(bPose* pose, const char* name)
        /* If not, create it and add it */
        chan = MEM_callocN(sizeof(bPoseChannel), "verifyPoseChannel");
        
-       strcpy (chan->name, name);
+       strncpy (chan->name, name, 31);
        /* init vars to prevent mat errors */
        chan->quat[0] = 1.0F;
        chan->size[0] = chan->size[1] = chan->size[2] = 1.0F;
@@ -346,7 +346,7 @@ bActionChannel *verify_action_channel(bAction *act, const char *name)
        if(chan==NULL) {
                if (!chan) {
                        chan = MEM_callocN (sizeof(bActionChannel), "actionChannel");
-                       strcpy (chan->name, name);
+                       strncpy (chan->name, name, 31);
                        BLI_addtail (&act->chanbase, chan);
                }
        }
@@ -831,7 +831,7 @@ static void do_nla(Object *ob, int blocktype)
                        actlength = strip->actend-strip->actstart;
                        striptime = (G.scene->r.cfra-(strip->start)) / length;
                        stripframe = (G.scene->r.cfra-(strip->start)) ;
-
+                       
                        if (striptime>=0.0){
                                
                                if(blocktype==ID_AR) 
@@ -998,6 +998,7 @@ void do_all_pose_actions(Object *ob)
 void do_all_object_actions(Object *ob)
 {
        if(ob==NULL) return;
+       if(ob->dup_group) return;       /* prevent conflicts, might add smarter check later */
        
        /* Do local action */
        if(ob->action && ((ob->nlaflag & OB_NLA_OVERRIDE)==0 || ob->nlastrips.first==NULL) ) {