769. [func] Improved error reporting when parsing rdata. [RT #740]
Two new error codes. Also push back the last token, if it makes sense to do so, so that it gets printed in the error message using RETTOK macro, rather than straight return or RETERR.
This commit is contained in:
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: ptr_12.c,v 1.36 2001/02/12 03:04:52 bwelling Exp $ */
|
||||
/* $Id: ptr_12.c,v 1.37 2001/03/06 22:10:58 marka Exp $ */
|
||||
|
||||
/* Reviewed: Thu Mar 16 14:05:12 PST 2000 by explorer */
|
||||
|
||||
@@ -40,7 +40,8 @@ fromtext_ptr(ARGS_FROMTEXT) {
|
||||
dns_name_init(&name, NULL);
|
||||
buffer_fromregion(&buffer, &token.value.as_region);
|
||||
origin = (origin != NULL) ? origin : dns_rootname;
|
||||
return (dns_name_fromtext(&name, &buffer, origin, downcase, target));
|
||||
RETTOK(dns_name_fromtext(&name, &buffer, origin, downcase, target));
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
static inline isc_result_t
|
||||
|
||||
Reference in New Issue
Block a user