]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Add spatch to replace isc_mem_put+isc_mem_detach with isc_mem_putanddetach
authorOndřej Surý <ondrej@sury.org>
Tue, 23 Jul 2019 21:28:02 +0000 (17:28 -0400)
committerOndřej Surý <ondrej@sury.org>
Wed, 31 Jul 2019 08:26:40 +0000 (10:26 +0200)
cocci/isc_mem_putanddetach.spatch [new file with mode: 0644]

diff --git a/cocci/isc_mem_putanddetach.spatch b/cocci/isc_mem_putanddetach.spatch
new file mode 100644 (file)
index 0000000..0f29779
--- /dev/null
@@ -0,0 +1,8 @@
+@@
+expression M;
+expression E1, E2;
+@@
+
+- isc_mem_put(M, E1, E2);
+- isc_mem_detach(&M);
++ isc_mem_putanddetach(&M, E1, E2);