summaryrefslogtreecommitdiff
path: root/memory
diff options
context:
space:
mode:
authorstriker <striker@13f79535-47bb-0310-9956-ffa450edef68>2003-11-06 00:43:32 +0000
committerstriker <striker@13f79535-47bb-0310-9956-ffa450edef68>2003-11-06 00:43:32 +0000
commita7d05ab90b25ea2698380875935394bfb5611254 (patch)
tree40d64db71a1f6d0e32e57cb92941936579ec9053 /memory
parent673d0521b4884546519c6b50241400fa102728da (diff)
downloadlibapr-a7d05ab90b25ea2698380875935394bfb5611254.tar.gz
* memory/unix/apr_pools.c
(pool_clear_debug): When there is a child pool present after cleanups have been run, we know that a cleanup created a child pool. This results in orphaned pools, so in debug mode, abort(). git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64735 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'memory')
-rw-r--r--memory/unix/apr_pools.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/memory/unix/apr_pools.c b/memory/unix/apr_pools.c
index 8d0e60b20..205cdba87 100644
--- a/memory/unix/apr_pools.c
+++ b/memory/unix/apr_pools.c
@@ -1399,6 +1399,10 @@ static void pool_clear_debug(apr_pool_t *pool, const char *file_line)
run_cleanups(&pool->cleanups);
pool->cleanups = NULL;
+ /* If new child pools showed up, this is a reason to raise a flag */
+ if (pool->child)
+ abort();
+
/* Free subprocesses */
free_proc_chain(pool->subprocesses);
pool->subprocesses = NULL;