Message ID | 20160610080507.19218400EE785@oldenburg.str.redhat.com |
---|---|
State | New |
Headers | show |
Thanks, this looks good too.
diff --git a/malloc/malloc.c b/malloc/malloc.c index 6f77d37..a077335 100644 --- a/malloc/malloc.c +++ b/malloc/malloc.c @@ -4608,7 +4608,12 @@ musable (void *mem) return malloc_check_get_size (p); if (chunk_is_mmapped (p)) - return chunksize (p) - 2 * SIZE_SZ; + { + if (DUMPED_MAIN_ARENA_CHUNK (p)) + return chunksize (p) - SIZE_SZ; + else + return chunksize (p) - 2 * SIZE_SZ; + } else if (inuse (p)) return chunksize (p) - SIZE_SZ; }