exit(EXIT_FAILURE);
}
+
+ free(progname);
filename = argv[0];
fp = fopen(filename, "r");
z = ldns_zone_new_frm_fp_l(fp, NULL, 0, LDNS_RR_CLASS_IN, &line_nr);
if (z) {
+/*
if (sort) {
ldns_zone_sort(z);
}
+*/
fprintf(stderr, "%d\n", (int) ldns_rr_list_rr_count(ldns_zone_rrs(z)) + 1);
ldns_zone_print(stdout, z);
ldns_zone_deep_free(z);
fprintf(stderr, "Syntax error at %d\n", line_nr);
}
fclose(fp);
-
+
exit(EXIT_SUCCESS);
}
/* read an entire line in from the file */
if (ldns_fget_token_l(fp, line, LDNS_PARSE_SKIP_SPACE, LDNS_MAX_LINELEN, line_nr) == -1) {
+ LDNS_FREE(line);
return NULL;
}