]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
clean up coccinelle patches for dns_name_copy()
authorEvan Hunt <each@isc.org>
Sat, 22 May 2021 00:59:09 +0000 (17:59 -0700)
committerEvan Hunt <each@isc.org>
Sat, 22 May 2021 07:37:27 +0000 (00:37 -0700)
no need for semantic patches to use dns_name_copynf() any longer.

cocci/dns_name_copy-with-result.spatch
cocci/dns_name_copy.spatch
cocci/dns_name_copynf.spatch

index c4555c3a7655ace80235d80bb4a369ba533b71f6..129d421d672c7976b023d344ec4350d5e14b6136 100644 (file)
@@ -5,7 +5,7 @@ statement S;
 
 - V = dns_name_copy(E1, E2, NULL);
 - if (V != ISC_R_SUCCESS) S
-+ RUNTIME_CHECK(dns_name_copy(E1, E2, NULL) == ISC_R_SUCCESS);
++ dns_name_copy(E1, E2);
 
 @@
 expression V, E1, E2;
@@ -14,7 +14,7 @@ statement S1, S2;
 
 - V = dns_name_copy(E1, E2, NULL);
 - if (V == ISC_R_SUCCESS) S1 else S2;
-+ RUNTIME_CHECK(dns_name_copy(E1, E2, NULL) == ISC_R_SUCCESS);
++ dns_name_copy(E1, E2);
 + S2
 
 @@
@@ -25,6 +25,6 @@ statement S1, S2;
 - V = dns_name_copy(E1, E2, NULL);
 - S1
 - if (V == ISC_R_SUCCESS) S2
-+ RUNTIME_CHECK(dns_name_copy(E1, E2, NULL) == ISC_R_SUCCESS);
++ dns_name_copy(E1, E2):
 + S1
 + S2
index 89e340cb4c410be5ec8a5f45e3a105adf1cdb043..0fa7e8557f06ed9e0a9edbac6eb53d91cb8c4ba7 100644 (file)
@@ -3,21 +3,21 @@ expression E1, E2;
 @@
 
 - dns_name_copy(E1, E2, NULL);
-+ RUNTIME_CHECK(dns_name_copy(E1, E2, NULL) == ISC_R_SUCCESS);
++ dns_name_copy(E1, E2);
 
 @@
 expression E1, E2;
 @@
 
 - (void)dns_name_copy(E1, E2, NULL);
-+ RUNTIME_CHECK(dns_name_copy(E1, E2, NULL) == ISC_R_SUCCESS);
++ dns_name_copy(E1, E2);
 
 @@
 expression E1, E2;
 @@
 
 - return (dns_name_copy(E1, E2, NULL));
-+ RUNTIME_CHECK(dns_name_copy(E1, E2, NULL) == ISC_R_SUCCESS);
++ dns_name_copy(E1, E2);
 + return (ISC_R_SUCCESS);
 
 // ./bin/named/query.c processing broken with this rule, fix manually
@@ -27,4 +27,4 @@ expression E1, E2;
 //
 // - V = dns_name_copy(E1, E2, NULL);
 // - RUNTIME_CHECK(V == ISC_R_SUCCESS);
-// + RUNTIME_CHECK(dns_name_copy(E1, E2, NULL) == ISC_R_SUCCESS);
+// + dns_name_copy(E1, E2);
index 7853b679e07c0b49264775e60937b51fd389639b..079a40e9d7c272a69728dade7394ac54855f466b 100644 (file)
@@ -3,4 +3,4 @@ expression E1, E2;
 @@
 
 - RUNTIME_CHECK(dns_name_copy(E1, E2, NULL) == ISC_R_SUCCESS);
-+ dns_name_copynf(E1, E2);
++ dns_name_copy(E1, E2);