diff options
author | Rickard Green <[email protected]> | 2016-08-12 14:04:29 +0200 |
---|---|---|
committer | Rickard Green <[email protected]> | 2016-08-12 14:04:29 +0200 |
commit | 49722eb3e32b92563e576283d84531797c2a3627 (patch) | |
tree | 878b6bacc39f80b5a3c72e7571558792ea20be9d /erts/emulator/beam/erl_hl_timer.c | |
parent | ce260c34b555e9e2d74fe9491e9e3a20cfcd6c82 (diff) | |
parent | 19db7510939149206017c925032d390da9a83fe9 (diff) | |
download | otp-49722eb3e32b92563e576283d84531797c2a3627.tar.gz otp-49722eb3e32b92563e576283d84531797c2a3627.tar.bz2 otp-49722eb3e32b92563e576283d84531797c2a3627.zip |
Merge branch 'maint-19' into maint
* maint-19:
Updated OTP version
Prepare release
Avoid segfault when printing slogan after crashdumping
Fix race causing lost wakeup on receive-after timeout
Diffstat (limited to 'erts/emulator/beam/erl_hl_timer.c')
-rw-r--r-- | erts/emulator/beam/erl_hl_timer.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/erts/emulator/beam/erl_hl_timer.c b/erts/emulator/beam/erl_hl_timer.c index ebeff51aac..f1bef28186 100644 --- a/erts/emulator/beam/erl_hl_timer.c +++ b/erts/emulator/beam/erl_hl_timer.c @@ -735,7 +735,10 @@ proc_timeout_common(Process *proc, void *tmr) if (tmr == (void *) erts_smp_atomic_cmpxchg_mb(&proc->common.timer, ERTS_PTMR_TIMEDOUT, (erts_aint_t) tmr)) { - erts_aint32_t state = erts_smp_atomic32_read_acqb(&proc->state); + erts_aint32_t state; + erts_smp_proc_lock(proc, ERTS_PROC_LOCKS_MSG_RECEIVE); + state = erts_smp_atomic32_read_acqb(&proc->state); + erts_smp_proc_unlock(proc, ERTS_PROC_LOCKS_MSG_RECEIVE); if (!(state & (ERTS_PSFLG_ACTIVE|ERTS_PSFLG_EXITING))) erts_schedule_process(proc, state, 0); return 1; |