Fix ixallocx_prof_sample() argument order reversal.

Fix ixallocx_prof() to pass usize_max and zero to ixallocx_prof_sample()
in the correct order.
This commit is contained in:
Jason Evans 2015-09-14 23:32:26 -07:00
parent ce9a4e3479
commit 23f6e103c8
2 changed files with 3 additions and 1 deletions

View File

@ -33,6 +33,8 @@ brevity. Much more detail can be found in the git revision history:
the result throughout the relevant functions that handle an allocation
event. Also add a missing check in prof_realloc(). These fixes protect
allocation events against concurrent prof_active changes.
- Fix ixallocx_prof() to pass usize_max and zero to ixallocx_prof_sample() in
the correct order.
* 4.0.0 (August 17, 2015)

View File

@ -2299,7 +2299,7 @@ ixallocx_prof(tsd_t *tsd, void *ptr, size_t old_usize, size_t size,
tctx = prof_alloc_prep(tsd, usize_max, prof_active, false);
if (unlikely((uintptr_t)tctx != (uintptr_t)1U)) {
usize = ixallocx_prof_sample(ptr, old_usize, size, extra,
alignment, zero, usize_max, tctx);
alignment, usize_max, zero, tctx);
} else {
usize = ixallocx_helper(ptr, old_usize, size, extra, alignment,
zero);