Catch NULL pointer deref if qdcount == 0

This commit is contained in:
Simon Kelley
2013-02-04 21:32:34 +00:00
parent bb2509fd2c
commit aa67fe7a8c

View File

@@ -470,7 +470,7 @@ size_t answer_auth(struct dns_header *header, char *limit, size_t qlen, time_t n
}
/* Add auth section */
if (auth)
if (auth && zone)
{
char *authname;
int newoffset, offset = 0;