mirror of
https://github.com/opnsense/src.git
synced 2026-06-11 01:30:30 -04:00
__crt_aligned_alloc_offset(): fix ov_index for backing allocation address
(cherry picked from commit 03a7c36ddb)
This commit is contained in:
parent
70e76f81e5
commit
cbf1bbe5c8
1 changed files with 1 additions and 1 deletions
|
|
@ -188,7 +188,7 @@ __crt_aligned_alloc_offset(size_t align, size_t size, size_t offset)
|
|||
x += offset;
|
||||
ov = cp2op((void *)x);
|
||||
ov1.ov_magic = AMAGIC;
|
||||
ov1.ov_index = x - (uintptr_t)mem - sizeof(union overhead);
|
||||
ov1.ov_index = x - (uintptr_t)mem + sizeof(union overhead);
|
||||
memcpy(ov, &ov1, sizeof(ov1));
|
||||
return ((void *)x);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue