Cleanup: some bad sizeof() usages.
authorBastien Montagne <montagne29@wanadoo.fr>
Thu, 18 Aug 2016 14:18:58 +0000 (16:18 +0200)
committerBastien Montagne <montagne29@wanadoo.fr>
Thu, 18 Aug 2016 14:18:58 +0000 (16:18 +0200)
source/blender/bmesh/tools/bmesh_decimate_collapse.c
source/blender/editors/mesh/editmesh_intersect.c

index 52a0df5b9d17b32c05bf2d6f677c8e025c70e41e..372d341f223b62ab0effb90c3641f1275fc1b1be 100644 (file)
@@ -430,7 +430,7 @@ static int *bm_edge_symmetry_map(BMesh *bm, unsigned int symmetry_axis, float li
 
        tree = BLI_kdtree_new(bm->totedge);
 
-       etable = MEM_mallocN(sizeof(BMEdge **) * bm->totedge, __func__);
+       etable = MEM_mallocN(sizeof(*etable) * bm->totedge, __func__);
        edge_symmetry_map = MEM_mallocN(sizeof(*edge_symmetry_map) * bm->totedge, __func__);
 
        BM_ITER_MESH_INDEX (e, &iter, bm, BM_EDGES_OF_MESH, i) {
index 281a8b2a02daaf6cb6d578c4fd4654be7062c419..de93211bec449536f58910b6d826e0f578eecacb 100644 (file)
@@ -439,7 +439,7 @@ static void bm_face_split_by_edges_island_connect(
         LinkNode *e_link, const int e_link_len,
         MemArena *mem_arena_edgenet)
 {
-       BMEdge **edge_arr = BLI_memarena_alloc(mem_arena_edgenet, sizeof(BMEdge **) * e_link_len);
+       BMEdge **edge_arr = BLI_memarena_alloc(mem_arena_edgenet, sizeof(*edge_arr) * e_link_len);
        int edge_arr_len = 0;
 
        while (e_link) {