static inline isc_result_t fromwire_hinfo(ARGS_FROMWIRE) { REQUIRE(type == 13); UNUSED(type); UNUSED(dctx); UNUSED(rdclass); UNUSED(options); RETERR(txt_fromwire(source, target)); return (txt_fromwire(source, target)); }
static inline isc_result_t fromwire_isdn(ARGS_FROMWIRE) { REQUIRE(type == 20); UNUSED(type); UNUSED(dctx); UNUSED(rdclass); UNUSED(options); RETERR(txt_fromwire(source, target)); if (buffer_empty(source)) return (ISC_R_SUCCESS); return (txt_fromwire(source, target)); }
static inline isc_result_t fromwire_naptr(ARGS_FROMWIRE) { dns_name_t name; isc_region_t sr; unsigned char *regex; REQUIRE(type == dns_rdatatype_naptr); UNUSED(type); UNUSED(rdclass); dns_decompress_setmethods(dctx, DNS_COMPRESS_NONE); dns_name_init(&name, NULL); /* * Order, preference. */ isc_buffer_activeregion(source, &sr); if (sr.length < 4) return (ISC_R_UNEXPECTEDEND); RETERR(mem_tobuffer(target, sr.base, 4)); isc_buffer_forward(source, 4); /* * Flags. */ RETERR(txt_fromwire(source, target)); /* * Service. */ RETERR(txt_fromwire(source, target)); /* * Regexp. */ regex = isc_buffer_used(target); RETERR(txt_fromwire(source, target)); RETERR(txt_valid_regex(regex)); /* * Replacement. */ return (dns_name_fromwire(&name, source, dctx, options, target)); }
static inline isc_result_t fromwire_gpos (ARGS_FROMWIRE) { int i; REQUIRE (type == 27); UNUSED (type); UNUSED (dctx); UNUSED (rdclass); UNUSED (options); for (i = 0; i < 3; i++) RETERR (txt_fromwire (source, target)); return (ISC_R_SUCCESS); }
static inline isc_result_t fromwire_x25(ARGS_FROMWIRE) { isc_region_t sr; REQUIRE(type == dns_rdatatype_x25); UNUSED(type); UNUSED(dctx); UNUSED(rdclass); UNUSED(options); isc_buffer_activeregion(source, &sr); if (sr.length < 5) return (DNS_R_FORMERR); return (txt_fromwire(source, target)); }
static inline isc_result_t generic_fromwire_txt(ARGS_FROMWIRE) { isc_result_t result; UNUSED(type); UNUSED(dctx); UNUSED(rdclass); UNUSED(options); do { result = txt_fromwire(source, target); if (result != ISC_R_SUCCESS) return (result); } while (!buffer_empty(source)); return (ISC_R_SUCCESS); }