From: Miek Gieben Date: Tue, 5 Apr 2005 14:23:45 +0000 (+0000) Subject: return the rr, up until the parsing went wrong X-Git-Tag: release-0.50~168 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=fb4ed27edd642c1b5dd5808f98c94941ffb303be;p=thirdparty%2Fldns.git return the rr, up until the parsing went wrong --- diff --git a/rr.c b/rr.c index 53853006..29d73a51 100644 --- a/rr.c +++ b/rr.c @@ -199,15 +199,16 @@ ldns_rr_new_frm_str(const char *str) if (!r) { printf("rdf conversion mismatch\n"); + /* return what we've got */ FREE(rdata); - return NULL; + return new; } ldns_rr_push_rdf(new, r); if (r_cnt > r_max) { printf("rdf data overflow"); FREE(rdata); - return NULL; + return new; } r_cnt++; } @@ -218,7 +219,7 @@ ldns_rr_new_frm_str(const char *str) if (!r) { printf("rdf conversion mismatch\n"); FREE(rdata); - return NULL; + return new; } ldns_rr_push_rdf(new, r);