Fix a Valgrind regression in chunk_alloc_wrapper().

This regression was caused by d412624b25
(Move retaining out of default chunk hooks).
This commit is contained in:
Elliot Ronaghan 2016-06-07 14:30:39 -07:00 committed by Jason Evans
parent 9de0094e6e
commit c7d5298027

View File

@ -493,10 +493,12 @@ chunk_alloc_wrapper(tsdn_t *tsdn, arena_t *arena, chunk_hooks_t *chunk_hooks,
if (ret == NULL)
return (NULL);
if (config_valgrind && chunk_hooks->alloc !=
chunk_alloc_default)
JEMALLOC_VALGRIND_MAKE_MEM_UNDEFINED(ret, chunksize);
}
if (config_valgrind && chunk_hooks->alloc != chunk_alloc_default)
JEMALLOC_VALGRIND_MAKE_MEM_UNDEFINED(ret, chunksize);
return (ret);
}