Add coccinelle script to remove pointless callocs

This commit is contained in:
Nick Mathewson 2014-09-16 11:11:17 -04:00
parent ef9a0d2048
commit 1bb10353ff

View File

@ -0,0 +1,13 @@
@@
expression a;
@@
- tor_calloc(1, a)
+ tor_malloc_zero(a)
@@
expression a;
@@
- tor_calloc(a, 1)
+ tor_malloc_zero(a)