apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From n..@apache.org
Subject svn commit: r659961 - in /apr/apr-util/trunk: CHANGES misc/apr_reslist.c
Date Sun, 25 May 2008 11:26:04 GMT
Author: niq
Date: Sun May 25 04:26:03 2008
New Revision: 659961

URL: http://svn.apache.org/viewvc?rev=659961&view=rev
Log:
Correction to r659802: apr_reslist fix to enforce ttl on idle resources
PR 42841

Modified:
    apr/apr-util/trunk/CHANGES
    apr/apr-util/trunk/misc/apr_reslist.c

Modified: apr/apr-util/trunk/CHANGES
URL: http://svn.apache.org/viewvc/apr/apr-util/trunk/CHANGES?rev=659961&r1=659960&r2=659961&view=diff
==============================================================================
--- apr/apr-util/trunk/CHANGES [utf-8] (original)
+++ apr/apr-util/trunk/CHANGES [utf-8] Sun May 25 04:26:03 2008
@@ -2,7 +2,7 @@
 Changes with APR-util 1.4.0
 
   *) Amend apr_reslist to expire resources whose idle time exceeds ttl.
-     PR 42841 [Tom Donovan, Nick Kew]
+     PR 42841 [Tom Donovan, Nick Kew, Ruediger Pluem]
 
   *) Add DTrace Probes to Hooks, making it easier to inspect APR Hook based
      applications with DTrace. [Theo Schlossnagle <jesus omniti.com>]

Modified: apr/apr-util/trunk/misc/apr_reslist.c
URL: http://svn.apache.org/viewvc/apr/apr-util/trunk/misc/apr_reslist.c?rev=659961&r1=659960&r2=659961&view=diff
==============================================================================
--- apr/apr-util/trunk/misc/apr_reslist.c (original)
+++ apr/apr-util/trunk/misc/apr_reslist.c Sun May 25 04:26:03 2008
@@ -303,7 +303,9 @@
         res = pop_resource(reslist);
         if (reslist->ttl && (now - res->freed >= reslist->ttl)) {
             /* this res is expired - kill it */
+            reslist->ntotal--;
             rv = destroy_resource(reslist, res);
+            free_container(reslist, res);
             if (rv != APR_SUCCESS) {
                 apr_thread_mutex_unlock(reslist->listlock);
                 return rv;  /* FIXME: this might cause unnecessary fails */



Mime
View raw message