summaryrefslogtreecommitdiff
path: root/buckets
diff options
context:
space:
mode:
authorStefan Fritsch <sf@apache.org>2013-01-26 20:43:02 +0000
committerStefan Fritsch <sf@apache.org>2013-01-26 20:43:02 +0000
commit3e2fdb0079fdf2f6adaa391e6f2f050bcce227fb (patch)
tree56f98b085fe75f97344dcad997d136663ab3e278 /buckets
parent55971642ad861e6fa2b31bc1b11bb5dff11092ef (diff)
downloadapr-3e2fdb0079fdf2f6adaa391e6f2f050bcce227fb.tar.gz
Don't corrupt the bucket allocator in out-of-mem situation
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1438960 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'buckets')
-rw-r--r--buckets/apr_buckets_alloc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/buckets/apr_buckets_alloc.c b/buckets/apr_buckets_alloc.c
index 7241a866b..3bfd5b07c 100644
--- a/buckets/apr_buckets_alloc.c
+++ b/buckets/apr_buckets_alloc.c
@@ -144,6 +144,7 @@ APR_DECLARE_NONSTD(void *) apr_bucket_alloc(apr_size_t in_size,
if (endp >= active->endp) {
list->blocks = apr_allocator_alloc(list->allocator, ALLOC_AMT);
if (!list->blocks) {
+ list->blocks = active;
return NULL;
}
list->blocks->next = active;