diff options
author | Tom Kistner <tom@duncanthrax.net> | 2009-04-29 19:58:00 +0000 |
---|---|---|
committer | Tom Kistner <tom@duncanthrax.net> | 2009-04-29 19:58:00 +0000 |
commit | 1bcd91b7a5bcb00db5f4897188bf99fc482176d1 (patch) | |
tree | 1103bd88752e2b598649f989f253ae7f7fae6058 | |
parent | 329b1c2cb5705e9e6b04df0470156ce615b95c2a (diff) | |
download | exim4-1bcd91b7a5bcb00db5f4897188bf99fc482176d1.tar.gz |
Do debug print when truncating DNS packets
-rw-r--r-- | src/src/dns.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/src/dns.c b/src/src/dns.c index 0b1d59d20..c4115ec51 100644 --- a/src/src/dns.c +++ b/src/src/dns.c @@ -1,4 +1,4 @@ -/* $Cambridge: exim/src/src/dns.c,v 1.17 2007/01/08 10:50:18 ph10 Exp $ */ +/* $Cambridge: exim/src/src/dns.c,v 1.17.2.1 2009/04/29 19:58:00 tom Exp $ */ /************************************************* * Exim - an Internet mail transport agent * @@ -562,7 +562,12 @@ if (running_in_test_harness) else dnsa->answerlen = res_search(CS name, C_IN, type, dnsa->answer, MAXPACKET); -if (dnsa->answerlen > MAXPACKET) dnsa->answerlen = MAXPACKET; +if (dnsa->answerlen > MAXPACKET) + { + DEBUG(D_dns) debug_printf("DNS lookup of %s (%s) resulted in overlong packet (size %d), truncating to %d.\n", + name, dns_text_type(type), dnsa->answerlen, MAXPACKET); + dnsa->answerlen = MAXPACKET; + } if (dnsa->answerlen < 0) switch (h_errno) { |