From a1d57e3f05f1602a07698e19f97f861d41f14775 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 8 Aug 2020 14:06:10 +1000 Subject: Cleanup: replace sizeof division with ARRAY_SIZE macro --- source/blender/makesrna/intern/makesrna.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/blender/makesrna/intern/makesrna.c') diff --git a/source/blender/makesrna/intern/makesrna.c b/source/blender/makesrna/intern/makesrna.c index 8781a3f448f..779e4363be0 100644 --- a/source/blender/makesrna/intern/makesrna.c +++ b/source/blender/makesrna/intern/makesrna.c @@ -3590,7 +3590,7 @@ static void rna_generate_struct_prototypes(FILE *f) if (found == 0) { fprintf(f, "struct %s;\n", struct_name); - if (all_structures >= sizeof(structures) / sizeof(structures[0])) { + if (all_structures >= ARRAY_SIZE(structures)) { printf("Array size to store all structures names is too small\n"); exit(1); } -- cgit v1.2.3