summaryrefslogtreecommitdiff
path: root/malloc
diff options
context:
space:
mode:
Diffstat (limited to 'malloc')
-rw-r--r--malloc/malloc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/malloc/malloc.c b/malloc/malloc.c
index f4612046cd..323ad84663 100644
--- a/malloc/malloc.c
+++ b/malloc/malloc.c
@@ -4233,7 +4233,8 @@ _int_free(mstate av, Void_t* mem)
#endif
) {
- if (__builtin_expect (chunksize (chunk_at_offset (p, size)) < MINSIZE, 0)
+ if (__builtin_expect (chunksize (chunk_at_offset (p, size)) < 2 * SIZE_SZ,
+ 0)
|| __builtin_expect (chunksize (chunk_at_offset (p, size))
>= av->system_mem, 0))
{