Skip to content

Commit 9da41ca

Browse files
committed
Revert "mimalloc: use "weak" random seed when statically linked"
In preparation for upgrading to a newer mimalloc version; This patch will not be needed anymore, as it has been implemented in a slightly different form in upstream mimalloc: 3e1d800e (potential fix for windows static linking with thread creation in dll's, 2022-11-07). Signed-off-by: Johannes Schindelin <[email protected]>
1 parent 5a99a20 commit 9da41ca

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

compat/mimalloc/init.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -302,11 +302,7 @@ static bool _mi_heap_init(void) {
302302
_mi_memcpy_aligned(tld, &tld_empty, sizeof(*tld));
303303
_mi_memcpy_aligned(heap, &_mi_heap_empty, sizeof(*heap));
304304
heap->thread_id = _mi_thread_id();
305-
#if defined(_WIN32) && !defined(MI_SHARED_LIB)
306-
_mi_random_init_weak(&heap->random); // match mi_heap_main_init()
307-
#else
308305
_mi_random_init(&heap->random);
309-
#endif
310306
heap->cookie = _mi_heap_random_next(heap) | 1;
311307
heap->keys[0] = _mi_heap_random_next(heap);
312308
heap->keys[1] = _mi_heap_random_next(heap);

0 commit comments

Comments
 (0)