From 533790ca7727d6112ab6d6b80a284fcbe8709712 Mon Sep 17 00:00:00 2001 From: Mansour Moufid Date: Sun, 19 Oct 2014 12:20:36 -0400 Subject: The second argument to tor_calloc should be a constant. Just like the conventional calloc. --- scripts/coccinelle/calloc.cocci | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/coccinelle/calloc.cocci b/scripts/coccinelle/calloc.cocci index f7d7ec0dc3..df0b61de06 100644 --- a/scripts/coccinelle/calloc.cocci +++ b/scripts/coccinelle/calloc.cocci @@ -2,7 +2,8 @@ @malloc_to_calloc@ identifier f =~ "(tor_malloc|tor_malloc_zero)"; -expression a, b; +expression a; +constant b; @@ - f(a * b) + tor_calloc(a, b) -- cgit v1.2.3-54-g00ecf