misc fixes found with clang's static checker.
[blender.git] / source / blender / editors / curve / editcurve.c
index 6193b6eb916b835c7b0dd3eb1a6c81e041197fca..4c869d25869c93462d42185574e29734fa7ce964 100644 (file)
@@ -732,7 +732,7 @@ static void calc_shapeKeys(Object *obedit)
                int totvert= count_curveverts(&editnurb->nurbs);
 
                float (*ofs)[3] = NULL;
-               float *oldkey, *newkey, *fp, *ofp;
+               float *oldkey, *newkey, *ofp;
 
                /* editing the base key should update others */
                if(cu->key->type==KEY_RELATIVE) {
@@ -776,7 +776,7 @@ static void calc_shapeKeys(Object *obedit)
                                                                for (j= 0; j < 3; ++j) {
                                                                        VECSUB(ofs[i], bezt->vec[j], oldbezt->vec[j]);
                                                                        i++;
-                                                                       fp+= 3;
+                                                                       // fp+= 3; // unused
                                                                }
                                                                ofs[i++][0]= bezt->alfa - oldbezt->alfa;
                                                        } else {
@@ -796,7 +796,7 @@ static void calc_shapeKeys(Object *obedit)
                                                        }
                                                        i += 2;
                                                        ++bp;
-                                                       fp += 4;
+                                                       // fp += 4; //unused
                                                }
                                        }
 
@@ -809,7 +809,7 @@ static void calc_shapeKeys(Object *obedit)
                while(currkey) {
                        int apply_offset = (ofs && (currkey != actkey) && (editnurb->shapenr-1 == currkey->relative));
 
-                       fp= newkey= MEM_callocN(cu->key->elemsize * totvert,  "currkey->data");
+                       float *fp= newkey= MEM_callocN(cu->key->elemsize * totvert,  "currkey->data");
                        ofp= oldkey = currkey->data;
 
                        nu= editnurb->nurbs.first;