aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/erl_process.c
diff options
context:
space:
mode:
authorBjörn-Egil Dahlberg <[email protected]>2011-09-13 10:23:52 +0200
committerBjörn-Egil Dahlberg <[email protected]>2011-09-13 10:23:52 +0200
commita40655461a03f6b075a1140810f020f5b2bf35b1 (patch)
tree7bbc04645cb2f1bf7a2f42ba7db1f114ec4dea3d /erts/emulator/beam/erl_process.c
parent8802241a20aaa3fb1e101f087812aa8db92a1ea7 (diff)
parent8d89620380fc8cff66ac6bab3e781058191ce0a3 (diff)
downloadotp-a40655461a03f6b075a1140810f020f5b2bf35b1.tar.gz
otp-a40655461a03f6b075a1140810f020f5b2bf35b1.tar.bz2
otp-a40655461a03f6b075a1140810f020f5b2bf35b1.zip
Merge branch 'egil/fix-run_queue/OTP-9537' into dev
* egil/fix-run_queue/OTP-9537: Make sure we have a run_queue
Diffstat (limited to 'erts/emulator/beam/erl_process.c')
-rw-r--r--erts/emulator/beam/erl_process.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/erts/emulator/beam/erl_process.c b/erts/emulator/beam/erl_process.c
index 2704359a8f..d8aed63544 100644
--- a/erts/emulator/beam/erl_process.c
+++ b/erts/emulator/beam/erl_process.c
@@ -5782,10 +5782,13 @@ erts_sched_stat_term(Process *p, int total)
void
erts_schedule_misc_op(void (*func)(void *), void *arg)
{
- ErtsRunQueue *rq = erts_get_runq_current(NULL);
+ ErtsRunQueue *rq;
ErtsMiscOpList *molp = misc_op_list_alloc();
+ ErtsSchedulerData *esdp = erts_get_scheduler_data();
- if (!rq) {
+ if (esdp) {
+ rq = esdp->run_queue;
+ } else {
/*
* This can only happen when the sys msg dispatcher
* thread schedules misc ops (this happens *very*