]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
mod_mem_cache: Fix concurrent removal of stale entries which could lead
authorWilliam A. Rowe Jr <wrowe@apache.org>
Thu, 30 Jun 2016 17:47:48 +0000 (17:47 +0000)
committerWilliam A. Rowe Jr <wrowe@apache.org>
Thu, 30 Jun 2016 17:47:48 +0000 (17:47 +0000)
to a crash.

PR: 43724
Submitted by: ylavic
Reviewed by: covener, wrowe

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@1750846 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
STATUS
modules/cache/mod_mem_cache.c

diff --git a/CHANGES b/CHANGES
index 23d4cee690e72c91a4e39211f09f1b46f749f148..3e35e84584a894593d557d55a6f2dd780cbf7b2c 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -12,6 +12,9 @@ Changes with Apache 2.2.32
      to avoid reusing it should the close be effective after some new request
      is ready to be sent.  [Yann Ylavic]
 
+  *) mod_mem_cache: Fix concurrent removal of stale entries which could lead
+     to a crash.  PR 43724.  [Yann Ylavic]
+
   *) mime.types: add common extension "m4a" for MPEG 4 Audio.
      PR 57895 [Dylan Millikin <dylan.millikin gmail.com>]
 
diff --git a/STATUS b/STATUS
index cfa31e4d923e06f88f8741db74f4b0eab7dce703..4a58f53836a8d741324c44ed30fc191658de6009 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -103,11 +103,6 @@ RELEASE SHOWSTOPPERS:
 PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
   [ start all new proposals below, under PATCHES PROPOSED. ]
 
-  *) mod_mem_cache: Fix concurrent removal of stale entries which could lead
-                    to a crash. PR 43724.
-     trunk patch: not applicable (2.2.x only)
-     2.2.x patch: http://home.apache.org/~ylavic/patches/httpd-2.2.x-mod_mem_cache-pr43724.patch
-     +1: ylavic, covener, wrowe
 
 
 PATCHES PROPOSED TO BACKPORT FROM TRUNK:
index b845b98330a9f8a9e3447b253dc0087374b147ca..c2a091c49532b4f7bac069b597e06b9321610ed1 100644 (file)
@@ -537,7 +537,7 @@ static int remove_url(cache_handle_t *h, apr_pool_t *p)
     }
 
     obj = h->cache_obj;
-    if (obj) {
+    if (obj && cache_find(sconf->cache_cache, obj->key) == obj) {
         cache_remove(sconf->cache_cache, obj);
         /* For performance, cleanup cache object after releasing the lock */
         cleanup = !apr_atomic_dec32(&obj->refcount);