[exim-cvs] cvs commit: exim/exim-src/src dns.c

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Tom Kistner
Fecha:  
A: exim-cvs
Asunto: [exim-cvs] cvs commit: exim/exim-src/src dns.c
tom 2009/04/29 20:58:01 BST

  Modified files:        (Branch: DEVEL_PDKIM)
    exim-src/src         dns.c 
  Log:
  Do debug print when truncating DNS packets


  Revision  Changes    Path
  1.17.2.1  +6 -1      exim/exim-src/src/dns.c


  Index: dns.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/dns.c,v
  retrieving revision 1.17
  retrieving revision 1.17.2.1
  diff -u -r1.17 -r1.17.2.1
  --- dns.c    8 Jan 2007 10:50:18 -0000    1.17
  +++ dns.c    29 Apr 2009 19:58:00 -0000    1.17.2.1
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/dns.c,v 1.17 2007/01/08 10:50:18 ph10 Exp $ */
  +/* $Cambridge: exim/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 @@
   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)
     {