mirror of
https://github.com/microsoft/mimalloc.git
synced 2024-12-28 05:50:51 +08:00
fix initialization of union padding; issue found through valgrind by @jasongibson
This commit is contained in:
parent
198ea4476c
commit
07a17dfeae
@ -205,6 +205,7 @@ static bool mi_region_try_alloc_os(size_t blocks, bool commit, bool allow_large,
|
|||||||
|
|
||||||
// and share it
|
// and share it
|
||||||
mi_region_info_t info;
|
mi_region_info_t info;
|
||||||
|
info.value = 0; // initialize the full union to zero
|
||||||
info.x.valid = true;
|
info.x.valid = true;
|
||||||
info.x.is_large = region_large;
|
info.x.is_large = region_large;
|
||||||
info.x.numa_node = (short)_mi_os_numa_node(tld);
|
info.x.numa_node = (short)_mi_os_numa_node(tld);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user