- added GCC warning -Wstrict-prototypes
[blender.git] / source / blender / editors / mesh / editmesh_mods.c
index c9934275f3fd088d87eb52cd50c4d55fbc5c5004..af03df34d5c28ecefc8e1a23b86d0c5da90609eb 100644 (file)
@@ -35,12 +35,10 @@ editmesh_mods.c, UI level access, no geometry changes
 
 #include <stdlib.h>
 #include <string.h>
-#include <math.h>
 
 #include "MEM_guardedalloc.h"
 
 
-
 #include "DNA_material_types.h"
 #include "DNA_meshdata_types.h"
 #include "DNA_modifier_types.h"
@@ -139,14 +137,13 @@ void EM_automerge(Scene *scene, Object *obedit, int update)
                (obedit && obedit->type==OB_MESH && (obedit->mode & OB_MODE_EDIT)) &&
                (me->mr==NULL)
          ) {
-               Mesh *me= (Mesh*)obedit->data;
                EditMesh *em= me->edit_mesh;
 
                len = removedoublesflag(em, 1, 1, scene->toolsettings->doublimit);
                if (len) {
                        em->totvert -= len; /* saves doing a countall */
                        if (update) {
-                               DAG_id_flush_update(obedit->data, OB_RECALC_DATA);
+                               DAG_id_flush_update(&me->id, OB_RECALC_DATA);
                        }
                }
        }