From 08551eee586eefa8c98f33b97679f259af50afab Mon Sep 17 00:00:00 2001 From: Jason Evans Date: Mon, 22 Feb 2016 15:01:37 -0800 Subject: [PATCH] Fix run_quantize_ceil(). In practice this bug had limited impact (and then only by increasing chunk fragmentation) because run_quantize_ceil() returned correct results except for inputs that could only arise from aligned allocation requests that required more than page alignment. This bug existed in the original run quantization implementation, which was introduced by 8a03cf039cd06f9fa6972711195055d865673966 (Implement cache index randomization for large allocations.). --- src/arena.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/arena.c b/src/arena.c index ff5b5fb8..97dea843 100644 --- a/src/arena.c +++ b/src/arena.c @@ -185,7 +185,7 @@ run_quantize_ceil(size_t size) * search would potentially find sufficiently aligned available * memory somewhere lower. */ - qsize = run_quantize_ceil_hard(size); + qsize = run_quantize_ceil_hard(qsize); } return (qsize); }