From: Jim Jagielski Date: Mon, 7 Feb 2011 19:32:31 +0000 (+0000) Subject: Only persist if we want it to X-Git-Tag: 2.3.11~92 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=055bebec525ccc76d4948f5039b9426935be55e2;p=thirdparty%2Fapache%2Fhttpd.git Only persist if we want it to git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1068072 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/slotmem/mod_slotmem_shm.c b/modules/slotmem/mod_slotmem_shm.c index 17b0311571b..23fdf82020a 100644 --- a/modules/slotmem/mod_slotmem_shm.c +++ b/modules/slotmem/mod_slotmem_shm.c @@ -43,6 +43,7 @@ #endif #define AP_SLOTMEM_IS_PREGRAB(t) (t->desc.type & AP_SLOTMEM_TYPE_PREGRAB) +#define AP_SLOTMEM_IS_PERSIST(t) (t->desc.type & AP_SLOTMEM_TYPE_PERSIST) /* The description of the slots to reuse the slotmem */ typedef struct { @@ -208,7 +209,9 @@ static apr_status_t cleanup_slotmem(void *param) ap_slotmem_instance_t *next = *mem; apr_pool_t *p = next->gpool; while (next) { - store_slotmem(next); + if (AP_SLOTMEM_IS_PERSIST(next)) { + store_slotmem(next); + } apr_shm_destroy((apr_shm_t *)next->shm); next = next->next; }