diff options
author | Joe Orton <jorton@apache.org> | 2021-07-02 13:35:25 +0000 |
---|---|---|
committer | Joe Orton <jorton@apache.org> | 2021-07-02 13:35:25 +0000 |
commit | 4accca566db5f31ba21d85ef9b121e19e0a4e363 (patch) | |
tree | 983d89e54b6fbe2f04176642a1a5e771ed08560c /memory/unix | |
parent | 360067271bc70745df724427e8d9303cf0645dee (diff) | |
download | apr-4accca566db5f31ba21d85ef9b121e19e0a4e363.tar.gz |
* memory/unix/apr_pools.c (apr_pool_create_unmanaged_ex): Destroy the
allocator if node allocation fails, rather than leaking it.
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1891202 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'memory/unix')
-rw-r--r-- | memory/unix/apr_pools.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/memory/unix/apr_pools.c b/memory/unix/apr_pools.c index b0f4c9ba0..2408655ec 100644 --- a/memory/unix/apr_pools.c +++ b/memory/unix/apr_pools.c @@ -1166,6 +1166,8 @@ APR_DECLARE(apr_status_t) apr_pool_create_unmanaged_ex(apr_pool_t **newpool, if (abort_fn) abort_fn(APR_ENOMEM); + apr_allocator_destroy(pool_allocator); + return APR_ENOMEM; } } |