2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-29 21:47:59 +00:00

code review changes

This commit is contained in:
James Brister 2000-03-16 01:31:03 +00:00
parent d5c518af63
commit 4f64d3ae93

View File

@ -15,7 +15,7 @@
* SOFTWARE. * SOFTWARE.
*/ */
/* $Id: gpos_27.c,v 1.11 2000/02/03 23:42:59 halley Exp $ */ /* $Id: gpos_27.c,v 1.12 2000/03/16 01:31:03 brister Exp $ */
/* RFC 1712 */ /* RFC 1712 */
@ -32,9 +32,9 @@ fromtext_gpos(dns_rdataclass_t rdclass, dns_rdatatype_t type,
REQUIRE(type == 27); REQUIRE(type == 27);
rdclass = rdclass; /*unused*/ UNUSED(rdclass);
origin = origin; /*unused*/ UNUSED(origin);
downcase = downcase; /*unused*/ UNUSED(downcase);
for (i = 0; i < 3 ; i++) { for (i = 0; i < 3 ; i++) {
RETERR(gettoken(lexer, &token, isc_tokentype_qstring, RETERR(gettoken(lexer, &token, isc_tokentype_qstring,
@ -53,7 +53,7 @@ totext_gpos(dns_rdata_t *rdata, dns_rdata_textctx_t *tctx,
REQUIRE(rdata->type == 27); REQUIRE(rdata->type == 27);
tctx = tctx; /*unused*/ UNUSED(tctx);
dns_rdata_toregion(rdata, &region); dns_rdata_toregion(rdata, &region);
@ -75,9 +75,9 @@ fromwire_gpos(dns_rdataclass_t rdclass, dns_rdatatype_t type,
REQUIRE(type == 27); REQUIRE(type == 27);
dctx = dctx; /*unused*/ UNUSED(dctx);
rdclass = rdclass; /*unused*/ UNUSED(rdclass);
downcase = downcase; /*unused*/ UNUSED(downcase);
for (i = 0 ; i < 3; i++) for (i = 0 ; i < 3; i++)
RETERR(txt_fromwire(source, target)); RETERR(txt_fromwire(source, target));
@ -85,17 +85,19 @@ fromwire_gpos(dns_rdataclass_t rdclass, dns_rdatatype_t type,
} }
static inline isc_result_t static inline isc_result_t
towire_gpos(dns_rdata_t *rdata, dns_compress_t *cctx, isc_buffer_t *target) { towire_gpos(dns_rdata_t *rdata, dns_compress_t *cctx, isc_buffer_t *target)
{
REQUIRE(rdata->type == 27); REQUIRE(rdata->type == 27);
cctx = cctx; /*unused*/ UNUSED(cctx);
return(mem_tobuffer(target, rdata->data, rdata->length)); return(mem_tobuffer(target, rdata->data, rdata->length));
} }
static inline int static inline int
compare_gpos(dns_rdata_t *rdata1, dns_rdata_t *rdata2) { compare_gpos(dns_rdata_t *rdata1, dns_rdata_t *rdata2)
{
isc_region_t r1; isc_region_t r1;
isc_region_t r2; isc_region_t r2;
@ -115,7 +117,7 @@ fromstruct_gpos(dns_rdataclass_t rdclass, dns_rdatatype_t type, void *source,
REQUIRE(type == 27); REQUIRE(type == 27);
rdclass = rdclass; /*unused*/ UNUSED(rdclass);
source = source; source = source;
target = target; target = target;
@ -124,7 +126,8 @@ fromstruct_gpos(dns_rdataclass_t rdclass, dns_rdatatype_t type, void *source,
} }
static inline isc_result_t static inline isc_result_t
tostruct_gpos(dns_rdata_t *rdata, void *target, isc_mem_t *mctx) { tostruct_gpos(dns_rdata_t *rdata, void *target, isc_mem_t *mctx)
{
REQUIRE(rdata->type == 27); REQUIRE(rdata->type == 27);
@ -135,7 +138,8 @@ tostruct_gpos(dns_rdata_t *rdata, void *target, isc_mem_t *mctx) {
} }
static inline void static inline void
freestruct_gpos(void *source) { freestruct_gpos(void *source)
{
REQUIRE(source != NULL); REQUIRE(source != NULL);
REQUIRE(ISC_FALSE); /* XXX */ REQUIRE(ISC_FALSE); /* XXX */
} }
@ -153,7 +157,8 @@ additionaldata_gpos(dns_rdata_t *rdata, dns_additionaldatafunc_t add,
} }
static inline isc_result_t static inline isc_result_t
digest_gpos(dns_rdata_t *rdata, dns_digestfunc_t digest, void *arg) { digest_gpos(dns_rdata_t *rdata, dns_digestfunc_t digest, void *arg)
{
isc_region_t r; isc_region_t r;
REQUIRE(rdata->type == 27); REQUIRE(rdata->type == 27);