Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
Merge branch 'mh/packed-ref-store' into next
[gitweb.git]
/
contrib
/
coccinelle
/
free.cocci
diff --git
a/contrib/coccinelle/free.cocci
b/contrib/coccinelle/free.cocci
index 35fb992621ff7c718d91258f4b8ac18a28db17ab..4490069df9650df6be58a8ad3f566329f7afd6ae 100644
(file)
--- a/
contrib/coccinelle/free.cocci
+++ b/
contrib/coccinelle/free.cocci
@@
-11,9
+11,8
@@
expression E;
free(E);
@@
-type T;
-T *ptr;
+expression E;
@@
-- free(
ptr
);
-
- ptr = NULL
;
-
+ FREE_AND_NULL(ptr)
;
+- free(
E
);
+
+ FREE_AND_NULL(E)
;
+
- E = NULL
;