summaryrefslogtreecommitdiff
path: root/contrib/coccinelle/xstrdup_or_null.cocci
blob: 3fceef132bf57623e04a080d03da9aff951f1c11 (plain)
1
2
3
4
5
6
7
@@
expression E;
expression V;
@@
- if (E)
-    V = xstrdup(E);
+ V = xstrdup_or_null(E);