Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2021-10-14 02:17:33 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-10-14 05:00:24 +0300
commit576142dc85c78ced792e3440a7665ea57e45a0cc (patch)
tree4b37d4897683f23a4f42ea476751cf9ed732e4de /source/blender/blenkernel/intern/multires_reshape_smooth.c
parentc6e956bbb148b80cbe03d59198f8257062434cff (diff)
Cleanup: pass the sizeof(..) as the second arg for array allocation
By argument naming and convention this is the intended argument order.
Diffstat (limited to 'source/blender/blenkernel/intern/multires_reshape_smooth.c')
-rw-r--r--source/blender/blenkernel/intern/multires_reshape_smooth.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/blenkernel/intern/multires_reshape_smooth.c b/source/blender/blenkernel/intern/multires_reshape_smooth.c
index 9fb158d2f84..3665d01926b 100644
--- a/source/blender/blenkernel/intern/multires_reshape_smooth.c
+++ b/source/blender/blenkernel/intern/multires_reshape_smooth.c
@@ -271,7 +271,7 @@ static void base_surface_grids_allocate(MultiresReshapeSmoothContext *reshape_sm
for (int grid_index = 0; grid_index < num_grids; ++grid_index) {
surface_grid[grid_index].points = MEM_calloc_arrayN(
- sizeof(SurfacePoint), grid_area, "delta grid displacement");
+ grid_area, sizeof(SurfacePoint), "delta grid displacement");
}
reshape_smooth_context->base_surface_grids = surface_grid;
@@ -576,19 +576,19 @@ static bool foreach_topology_info(const SubdivForeachContext *foreach_context,
/* NOTE: Calloc so the counters are re-set to 0 "for free". */
reshape_smooth_context->geometry.num_vertices = num_vertices;
reshape_smooth_context->geometry.vertices = MEM_calloc_arrayN(
- sizeof(Vertex), num_vertices, "smooth vertices");
+ num_vertices, sizeof(Vertex), "smooth vertices");
reshape_smooth_context->geometry.max_edges = max_edges;
reshape_smooth_context->geometry.edges = MEM_malloc_arrayN(
- sizeof(Edge), max_edges, "smooth edges");
+ max_edges, sizeof(Edge), "smooth edges");
reshape_smooth_context->geometry.num_corners = num_loops;
reshape_smooth_context->geometry.corners = MEM_malloc_arrayN(
- sizeof(Corner), num_loops, "smooth corners");
+ num_loops, sizeof(Corner), "smooth corners");
reshape_smooth_context->geometry.num_faces = num_polygons;
reshape_smooth_context->geometry.faces = MEM_malloc_arrayN(
- sizeof(Face), num_polygons, "smooth faces");
+ num_polygons, sizeof(Face), "smooth faces");
return true;
}