diff options
author | Björn-Egil Dahlberg <[email protected]> | 2010-06-07 11:25:59 +0000 |
---|---|---|
committer | Erlang/OTP <[email protected]> | 2010-06-07 11:25:59 +0000 |
commit | 9e69214f56cd5031f684da71a9eb24fa7003d1f2 (patch) | |
tree | 26446f5d6db24fc8a7246a6d637de9226fb0b9a1 /erts/emulator/sys/win32 | |
parent | 8f243a67b6a710b076964a7043de7adc99bfa6d5 (diff) | |
download | otp-9e69214f56cd5031f684da71a9eb24fa7003d1f2.tar.gz otp-9e69214f56cd5031f684da71a9eb24fa7003d1f2.tar.bz2 otp-9e69214f56cd5031f684da71a9eb24fa7003d1f2.zip |
Merge OTP-8681
Diffstat (limited to 'erts/emulator/sys/win32')
-rw-r--r-- | erts/emulator/sys/win32/sys.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/erts/emulator/sys/win32/sys.c b/erts/emulator/sys/win32/sys.c index d3921a14f8..bd02cf85eb 100644 --- a/erts/emulator/sys/win32/sys.c +++ b/erts/emulator/sys/win32/sys.c @@ -2986,7 +2986,15 @@ static void ethr_internal_free(void *ptr) { erts_free(ERTS_ALC_T_ETHR_INTERNAL, ptr); } -#endif + +#ifdef ERTS_ENABLE_LOCK_COUNT +static void +thr_create_prepare_child(void *vtcdp) +{ + erts_lcnt_thread_setup(); +} +#endif /* ERTS_ENABLE_LOCK_COUNT */ +#endif /* USE_THREADS */ void erts_sys_pre_init(void) @@ -3000,6 +3008,11 @@ erts_sys_pre_init(void) eid.alloc = ethr_internal_alloc; eid.realloc = ethr_internal_realloc; eid.free = ethr_internal_free; + +#ifdef ERTS_ENABLE_LOCK_COUNT + eid.thread_create_child_func = thr_create_prepare_child; +#endif + erts_thr_init(&eid); #ifdef ERTS_ENABLE_LOCK_COUNT erts_lcnt_init(); |