mirror of
http://thekelleys.org.uk/git/dnsmasq.git
synced 2026-10-20 11:29:35 +00:00
Add logging for DNS error returns from upstream and local configuration.
This commit is contained in:
1 parent
0669ee7a69
commit
07ed585c38
4 files changed
+52
-12
No files matched your search
+13
@@ -1598,6 +1598,19 @@ void log_query(unsigned int flags, char *name, struct all_addr *addr, char *arg)
|
||||
{
|
||||
if (flags & F_KEYTAG)
|
||||
sprintf(daemon->addrbuff, arg, addr->addr.log.keytag, addr->addr.log.algo, addr->addr.log.digest);
|
||||
else if (flags & F_RCODE)
|
||||
{
|
||||
unsigned int rcode = addr->addr.rcode.rcode;
|
||||
|
||||
if (rcode == SERVFAIL)
|
||||
dest = "SERVFAIL";
|
||||
else if (rcode == REFUSED)
|
||||
dest = "REFUSED";
|
||||
else if (rcode == NOTIMP)
|
||||
dest = "not implemented";
|
||||
else
|
||||
sprintf(daemon->addrbuff, "%u", rcode);
|
||||
}
|
||||
else
|
||||
{
|
||||
#ifdef HAVE_IPV6
|
||||
|
||||
Reference in new issue
Block a user