[prev in list] [next in list] [prev in thread] [next in thread]
List: apache-cvs
Subject: svn commit: r1087333 - /httpd/httpd/trunk/modules/slotmem/mod_slotmem_shm.c
From: jim () apache ! org
Date: 2011-03-31 15:12:13
Message-ID: 20110331151213.5931523889E0 () eris ! apache ! org
[Download RAW message or body]
Author: jim
Date: Thu Mar 31 15:12:13 2011
New Revision: 1087333
URL: http://svn.apache.org/viewvc?rev=1087333&view=rev
Log:
Don't kill me mister...
Modified:
httpd/httpd/trunk/modules/slotmem/mod_slotmem_shm.c
Modified: httpd/httpd/trunk/modules/slotmem/mod_slotmem_shm.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/slotmem/mod_slotmem_shm.c?rev=1087333&r1=1087332&r2=1087333&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/slotmem/mod_slotmem_shm.c (original)
+++ httpd/httpd/trunk/modules/slotmem/mod_slotmem_shm.c Thu Mar 31 15:12:13 2011
@@ -207,7 +207,6 @@ static apr_status_t cleanup_slotmem(void
if (*mem) {
ap_slotmem_instance_t *next = *mem;
- apr_pool_t *p = next->gpool;
while (next) {
if (AP_SLOTMEM_IS_PERSIST(next)) {
store_slotmem(next);
@@ -215,11 +214,6 @@ static apr_status_t cleanup_slotmem(void
apr_shm_destroy((apr_shm_t *)next->shm);
next = next->next;
}
- apr_pool_destroy(p);
- } else {
- /* If shared mem was never called, then just remove
- * the global pool */
- apr_pool_destroy(gpool);
}
return APR_SUCCESS;
}
@@ -572,7 +566,7 @@ static apr_status_t slotmem_grab(ap_slot
}
}
if (i >= slot->desc.num) {
- return APR_ENOSHMAVAIL;
+ return APR_EINVAL;
}
*inuse = 1;
*id = i;
@@ -623,7 +617,9 @@ static const ap_slotmem_provider_t *slot
/* initialise the global pool */
static void slotmem_shm_initgpool(apr_pool_t *p)
{
- gpool = p;
+ if (!gpool && p) {
+ gpool = p;
+ }
}
/* Add the pool_clean routine */
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic