From 8ea9492cf3505c379d1c573b02db90e6b480cc75 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sat, 13 Dec 2025 10:46:28 +0900 Subject: cocci: use MEMZERO_ARRAY() a bit more Existing code in files that have been fairly stable trigger the "make coccicheck" suggestions due to the new check. Rewrite them to use MEMZERO_ARRAY() Signed-off-by: Junio C Hamano --- linear-assignment.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'linear-assignment.c') diff --git a/linear-assignment.c b/linear-assignment.c index 5416cbcf40..97b4f75058 100644 --- a/linear-assignment.c +++ b/linear-assignment.c @@ -20,8 +20,8 @@ void compute_assignment(int column_count, int row_count, int *cost, int i, j, phase; if (column_count < 2) { - memset(column2row, 0, sizeof(int) * column_count); - memset(row2column, 0, sizeof(int) * row_count); + MEMZERO_ARRAY(column2row, column_count); + MEMZERO_ARRAY(row2column, row_count); return; } -- cgit v1.3-5-g9baa