diff options
author | Rickard Green <[email protected]> | 2018-04-11 16:05:12 +0200 |
---|---|---|
committer | Rickard Green <[email protected]> | 2018-04-11 16:05:12 +0200 |
commit | cb9fb22d0798f162c8a580d2f6751d7de0ae63dd (patch) | |
tree | 5504aae30a69067342b161288c5a7cb3bda747b9 | |
parent | 83a48624cef51c5db7ec97a8a2556ff1d4ec5832 (diff) | |
parent | 0bb8aac23842e04e522cd98ed397339675a41ad8 (diff) | |
download | otp-cb9fb22d0798f162c8a580d2f6751d7de0ae63dd.tar.gz otp-cb9fb22d0798f162c8a580d2f6751d7de0ae63dd.tar.bz2 otp-cb9fb22d0798f162c8a580d2f6751d7de0ae63dd.zip |
Merge branch 'rickard/signals/OTP-14589'
* rickard/signals/OTP-14589:
Fix seq trace
Fix bad assert
-rw-r--r-- | erts/emulator/beam/erl_proc_sig_queue.c | 18 | ||||
-rw-r--r-- | erts/emulator/beam/erl_process.c | 1 |
2 files changed, 10 insertions, 9 deletions
diff --git a/erts/emulator/beam/erl_proc_sig_queue.c b/erts/emulator/beam/erl_proc_sig_queue.c index 1ba0b789ec..b32ba1b2e6 100644 --- a/erts/emulator/beam/erl_proc_sig_queue.c +++ b/erts/emulator/beam/erl_proc_sig_queue.c @@ -723,7 +723,7 @@ erts_proc_sig_fetch(Process *proc) ERTS_HDBG_CHECK_SIGNAL_PRIV_QUEUE(proc); } -void do_seq_trace_output(Eterm to, Eterm token, Eterm msg); +static void do_seq_trace_output(Eterm to, Eterm token, Eterm msg); static void send_gen_exit_signal(Process *c_p, Eterm from_tag, @@ -869,7 +869,7 @@ send_gen_exit_signal(Process *c_p, Eterm from_tag, } } -void +static void do_seq_trace_output(Eterm to, Eterm token, Eterm msg) { /* @@ -887,15 +887,17 @@ do_seq_trace_output(Eterm to, Eterm token, Eterm msg) else rp = erts_proc_lookup_raw_inc_refc(to); - erts_proc_lock(rp, ERTS_PROC_LOCK_MSGQ); + if (rp) { + erts_proc_lock(rp, ERTS_PROC_LOCK_MSGQ); - if (!ERTS_PROC_IS_EXITING(rp)) - seq_trace_output(token, msg, SEQ_TRACE_SEND, to, rp); + if (!ERTS_PROC_IS_EXITING(rp)) + seq_trace_output(token, msg, SEQ_TRACE_SEND, to, rp); - erts_proc_unlock(rp, ERTS_PROC_LOCK_MSGQ); + erts_proc_unlock(rp, ERTS_PROC_LOCK_MSGQ); - if (!is_normal_sched) - erts_proc_dec_refc(rp); + if (!is_normal_sched) + erts_proc_dec_refc(rp); + } } void diff --git a/erts/emulator/beam/erl_process.c b/erts/emulator/beam/erl_process.c index be1306cd79..ba0a9fbc79 100644 --- a/erts/emulator/beam/erl_process.c +++ b/erts/emulator/beam/erl_process.c @@ -10785,7 +10785,6 @@ exit_permanent_prio_elevation(Process *c_p, erts_aint32_t state) while (1) { erts_aint32_t aprio, uprio, n, e; ASSERT(a & ERTS_PSFLG_EXITING); - ASSERT(!(a & ERTS_PSFLG_FREE)); aprio = ERTS_PSFLGS_GET_ACT_PRIO(a); uprio = ERTS_PSFLGS_GET_USR_PRIO(a); if (aprio >= uprio) |