httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From minf...@apache.org
Subject cvs commit: httpd-2.0/modules/ldap util_ldap_cache_mgr.c
Date Sun, 03 Oct 2004 16:24:54 GMT
minfrin     2004/10/03 09:24:54

  Modified:    .        CHANGES
               modules/ldap util_ldap_cache_mgr.c
  Log:
  mod_ldap: prevent the possiblity of an infinite loop in the LDAP
  statistics display.
  PR: 29216
  Submitted by:	Graham Leggett
  
  Revision  Changes    Path
  1.1606    +3 -0      httpd-2.0/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/CHANGES,v
  retrieving revision 1.1605
  retrieving revision 1.1606
  diff -u -r1.1605 -r1.1606
  --- CHANGES	2 Oct 2004 16:59:52 -0000	1.1605
  +++ CHANGES	3 Oct 2004 16:24:53 -0000	1.1606
  @@ -2,6 +2,9 @@
   
     [Remove entries to the current 2.0 section below, when backported]
   
  +  *) mod_ldap: prevent the possiblity of an infinite loop in the LDAP
  +     statistics display. PR 29216 [Graham Leggett]
  +
     *) mod_disk_cache: Do not store hop-by-hop headers.  [Justin Erenkrantz]
   
     *) mod_cache: Try to correctly follow RFC 2616 13.3 on validating stale
  
  
  
  1.11      +5 -2      httpd-2.0/modules/ldap/util_ldap_cache_mgr.c
  
  Index: util_ldap_cache_mgr.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/ldap/util_ldap_cache_mgr.c,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- util_ldap_cache_mgr.c	22 Sep 2004 16:50:29 -0000	1.10
  +++ util_ldap_cache_mgr.c	3 Oct 2004 16:24:53 -0000	1.11
  @@ -469,8 +469,11 @@
       for (i=0; i < cache->size; ++i) {
           if (cache->nodes[i] != NULL) {
               nchains++;
  -            for (n = cache->nodes[i]; n != NULL; n = n->next)
  -            totchainlen++;
  +            for (n = cache->nodes[i];
  +                 n != NULL && n != n->next;
  +                 n = n->next) {
  +            	totchainlen++;
  +            }
           }
       }
       chainlen = nchains? (double)totchainlen / (double)nchains : 0;
  
  
  

Mime
View raw message