This remove's C++ style casts from the return value of malloc/calloc.

see 403fd722ace1d98d3cfe17bbee1382bf58040466
---
 scripts/coccinelle/xalloc_cast.cocci | 11 +++++++++++
 1 file changed, 11 insertions(+)
 create mode 100644 scripts/coccinelle/xalloc_cast.cocci

diff --git a/scripts/coccinelle/xalloc_cast.cocci 
b/scripts/coccinelle/xalloc_cast.cocci
new file mode 100644
index 000000000..75baa0022
--- /dev/null
+++ b/scripts/coccinelle/xalloc_cast.cocci
@@ -0,0 +1,11 @@
+@@
+type T;
+@@
+
+- (T*)
+(
+malloc
+|
+calloc
+)
+  (...)
-- 
2.33.0


Reply via email to