Bugfix unitialized memory access with root lookups

This commit is contained in:
Willem Toorop 2016-03-21 15:39:33 +01:00
parent 468f2997ff
commit 0d9d5a5eb7
1 changed files with 1 additions and 0 deletions

View File

@ -840,6 +840,7 @@ _getdns_dns_req_new(getdns_context *context, getdns_eventloop *loop,
}
} else if (result->append_name ==
GETDNS_APPEND_NAME_ONLY_TO_SINGLE_LABEL_AFTER_FAILURE &&
result->name[0] &&
result->name[result->name[0]+1] != 0) {
/* We have multiple labels, no appending */
result->suffix_len = no_suffixes[0];