diff options
Diffstat (limited to 'malloc/malloc.c')
| -rw-r--r-- | malloc/malloc.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/malloc/malloc.c b/malloc/malloc.c index 0f1796c913..bd562df959 100644 --- a/malloc/malloc.c +++ b/malloc/malloc.c @@ -1,5 +1,5 @@ /* Malloc implementation for multiple threads without lock contention. - Copyright (C) 1996-2009, 2010, 2011, 2012 Free Software Foundation, Inc. + Copyright (C) 1996-2012 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Wolfram Gloger <wg@malloc.de> and Doug Lea <dl@cs.oswego.edu>, 2001. @@ -4563,6 +4563,9 @@ musable(void* mem) mchunkptr p; if (mem != 0) { p = mem2chunk(mem); + + if (__builtin_expect(using_malloc_checking == 1, 0)) + return malloc_check_get_size(p); if (chunk_is_mmapped(p)) return chunksize(p) - 2*SIZE_SZ; else if (inuse(p)) |
