[exim-cvs] cvs commit: exim/exim-doc/doc-txt ChangeLog exim…

Pàgina inicial
Delete this message
Reply to this message
Autor: Philip Hazel
Data:  
A: exim-cvs
Assumpte: [exim-cvs] cvs commit: exim/exim-doc/doc-txt ChangeLog exim/exim-src/src/lookups lsearch.c
ph10 2005/11/15 09:44:34 GMT

  Modified files:
    exim-doc/doc-txt     ChangeLog 
    exim-src/src/lookups lsearch.c 
  Log:
  Discard the values of the numeric variables after a wildlsearch lookup.


  Revision  Changes    Path
  1.261     +4 -0      exim/exim-doc/doc-txt/ChangeLog
  1.5       +10 -1     exim/exim-src/src/lookups/lsearch.c


  Index: ChangeLog
  ===================================================================
  RCS file: /home/cvs/exim/exim-doc/doc-txt/ChangeLog,v
  retrieving revision 1.260
  retrieving revision 1.261
  diff -u -r1.260 -r1.261
  --- ChangeLog    14 Nov 2005 16:09:54 -0000    1.260
  +++ ChangeLog    15 Nov 2005 09:44:33 -0000    1.261
  @@ -1,4 +1,4 @@
  -$Cambridge: exim/exim-doc/doc-txt/ChangeLog,v 1.260 2005/11/14 16:09:54 ph10 Exp $
  +$Cambridge: exim/exim-doc/doc-txt/ChangeLog,v 1.261 2005/11/15 09:44:33 ph10 Exp $


   Change log file for Exim from version 4.21
   -------------------------------------------
  @@ -121,6 +121,10 @@
         to the default Received: header definition.


   PH/12 Added log selector acl_warn_skipped (default on).
  +
  +PH/13 After a successful wildlsearch lookup, discard the values of numeric
  +      variables because (a) they are in the wrong storage pool and (b) even if
  +      they were copied, it wouldn't work properly because of the caching.



Exim version 4.54

  Index: lsearch.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/lookups/lsearch.c,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- lsearch.c    27 Jun 2005 14:29:44 -0000    1.4
  +++ lsearch.c    15 Nov 2005 09:44:33 -0000    1.5
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/lookups/lsearch.c,v 1.4 2005/06/27 14:29:44 ph10 Exp $ */
  +/* $Cambridge: exim/exim-src/src/lookups/lsearch.c,v 1.5 2005/11/15 09:44:33 ph10 Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -197,7 +197,16 @@
         if (rc == FAIL) continue;
         if (rc == DEFER) return DEFER;
         }
  -    break;      /* Key matched */
  +
  +    /* The key has matched. If the search involved a regular expression, it
  +    might have caused numerical variables to be set. However, their values will
  +    be in the wrong storage pool for external use. Copying them to the standard
  +    pool is not feasible because of the caching of lookup results - a repeated
  +    lookup will not match the regular expression again. Therefore, we flatten
  +    all numeric variables at this point. */
  +
  +    expand_nmax = -1;
  +    break;


       /* Compare an ip address against a list of network/ip addresses. We have to
       allow for the "*" case specially. */