Skip to content

Commit

Permalink
Set default to trace start point to "."
Browse files Browse the repository at this point in the history
  • Loading branch information
jiuka committed Aug 1, 2014
1 parent 0a5cde4 commit 2f1de92
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions dns/check_dnssec_trace.c
Expand Up @@ -43,7 +43,7 @@ const char *progusage = "[-H host] -D domain [-T domain] [-k file] [-t timeout]"
/* Global Vars */
const char *hostname;
char *domainname;
char *domaintrace;
char *domaintrace = ".";
ldns_rr_list *trusted_keys = NULL;
int checkState;

Expand Down Expand Up @@ -81,13 +81,9 @@ int main(int argc, char **argv) {
if (!rd_domain)
unknown("Illegal domain name");

if (domaintrace) {
rd_trace = ldns_dname_new_frm_str(domaintrace);
if (!rd_trace)
unknown("Illegal trace domain name");
} else {
rd_trace = ldns_dname_new_frm_str(".");
}
rd_trace = ldns_dname_new_frm_str(domaintrace);
if (!rd_trace)
unknown("Illegal trace domain name");

/* Check domain is subdomain from trace start */
if (!ldns_dname_is_subdomain(rd_domain, rd_trace)) {
Expand Down

0 comments on commit 2f1de92

Please sign in to comment.