2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-22 01:59:26 +00:00
bind/cocci/dns_message_gettemp.disabled
Ondřej Surý 33ba0057a7 Cleanup dns_message_gettemp*() functions - they cannot fail
The dns_message_gettempname(), dns_message_gettemprdata(),
dns_message_gettemprdataset(), and dns_message_gettemprdatalist() always
succeeds because the memory allocation cannot fail now.  Change the API
to return void and cleanup all the use of aforementioned functions.
2022-05-17 12:39:25 +02:00

156 lines
1.5 KiB
Plaintext

@@
statement S;
expression V;
@@
- V =
dns_message_gettempname(...);
- if (V != ISC_R_SUCCESS) S
@@
statement S;
expression V;
@@
- V =
dns_message_gettemprdata(...);
- if (V != ISC_R_SUCCESS) S
@@
statement S;
expression V;
@@
- V =
dns_message_gettemprdataset(...);
- if (V != ISC_R_SUCCESS) S
@@
statement S;
expression V;
@@
- V =
dns_message_gettemprdatalist(...);
- if (V != ISC_R_SUCCESS) S
@@
@@
- CHECK(
dns_message_gettempname(...)
- )
@@
@@
- CHECK(
dns_message_gettemprdata(...)
- )
@@
@@
- CHECK(
dns_message_gettemprdataset(...)
- )
@@
@@
- CHECK(
dns_message_gettemprdatalist(...)
- )
@@
@@
- RETERR(
dns_message_gettempname(...)
- )
@@
@@
- RETERR(
dns_message_gettemprdata(...)
- )
@@
@@
- RETERR(
dns_message_gettemprdataset(...)
- )
@@
@@
- RETERR(
dns_message_gettemprdatalist(...)
- )
@@
expression V;
@@
- V =
dns_message_gettempname(...);
- check_result(V, ...);
@@
expression V;
@@
- V =
dns_message_gettemprdata(...);
- check_result(V, ...);
@@
expression V;
@@
- V =
dns_message_gettemprdataset(...);
- check_result(V, ...);
@@
expression V;
@@
- V =
dns_message_gettemprdatalist(...);
- check_result(V, ...);
@@
expression V;
@@
- V =
dns_message_gettempname(...);
- CHECK(..., V);
@@
expression V;
@@
- V =
dns_message_gettemprdata(...);
- CHECK(..., V);
@@
expression V;
@@
- V =
dns_message_gettemprdataset(...);
- CHECK(..., V);
@@
expression V;
@@
- V =
dns_message_gettemprdatalist(...);
- CHECK(..., V);