summaryrefslogtreecommitdiff
path: root/buckets/ap_buckets_heap.c
diff options
context:
space:
mode:
Diffstat (limited to 'buckets/ap_buckets_heap.c')
-rw-r--r--buckets/ap_buckets_heap.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/buckets/ap_buckets_heap.c b/buckets/ap_buckets_heap.c
index c8fc48f0..29e3c57f 100644
--- a/buckets/ap_buckets_heap.c
+++ b/buckets/ap_buckets_heap.c
@@ -133,7 +133,8 @@ API_EXPORT(ap_bucket *) ap_bucket_make_heap(ap_bucket *b,
b->read = heap_read;
b->setaside = NULL;
- *w = length;
+ if (w)
+ *w = length;
return b;
}