diff options
Diffstat (limited to 'lang')
-rw-r--r-- | lang/erlang/Makefile | 2 | ||||
-rw-r--r-- | lang/erlang/files/patch-erts_emulator_beam_utils.c | 36 | ||||
-rw-r--r-- | lang/erlang14/Makefile | 2 | ||||
-rw-r--r-- | lang/erlang14/files/patch-erts_emulator_beam_utils.c | 36 |
4 files changed, 74 insertions, 2 deletions
diff --git a/lang/erlang/Makefile b/lang/erlang/Makefile index 785021b672aa..252635012826 100644 --- a/lang/erlang/Makefile +++ b/lang/erlang/Makefile @@ -7,7 +7,7 @@ PORTNAME= erlang PORTVERSION= r11b2 -PORTREVISION= 1 +PORTREVISION= 2 PORTEPOCH= 1 CATEGORIES= lang parallel MASTER_SITES= http://www.erlang.org/download/ \ diff --git a/lang/erlang/files/patch-erts_emulator_beam_utils.c b/lang/erlang/files/patch-erts_emulator_beam_utils.c new file mode 100644 index 000000000000..58e675168a85 --- /dev/null +++ b/lang/erlang/files/patch-erts_emulator_beam_utils.c @@ -0,0 +1,36 @@ + +$FreeBSD$ + +--- erts/emulator/beam/utils.c.orig ++++ erts/emulator/beam/utils.c +@@ -2999,15 +2999,16 @@ + static void + ptimer_timeout(ErtsSmpPTimer *ptimer) + { +- if (!(ptimer->timer.flags & ERTS_PTMR_FLG_CANCELLED)) { + if (is_internal_pid(ptimer->timer.id)) { + Process *p; +- p = erts_pid2proc(NULL, +- 0, +- ptimer->timer.id, +- ERTS_PROC_LOCK_MAIN|ERTS_PROC_LOCK_STATUS); ++ p = erts_pid2proc_opt(NULL, ++ 0, ++ ptimer->timer.id, ++ ERTS_PROC_LOCK_MAIN|ERTS_PROC_LOCK_STATUS, ++ ERTS_P2P_FLG_ALLOW_OTHER_X); + if (p) { +- if (!(ptimer->timer.flags & ERTS_PTMR_FLG_CANCELLED)) { ++ if (!p->is_exiting ++ && !(ptimer->timer.flags & ERTS_PTMR_FLG_CANCELLED)) { + ASSERT(*ptimer->timer.timer_ref == ptimer); + *ptimer->timer.timer_ref = NULL; + (*ptimer->timer.timeout_func)(p); +@@ -3028,7 +3029,6 @@ + erts_smp_io_unlock(); + } + } +- } + free_ptimer(ptimer); + } + diff --git a/lang/erlang14/Makefile b/lang/erlang14/Makefile index 785021b672aa..252635012826 100644 --- a/lang/erlang14/Makefile +++ b/lang/erlang14/Makefile @@ -7,7 +7,7 @@ PORTNAME= erlang PORTVERSION= r11b2 -PORTREVISION= 1 +PORTREVISION= 2 PORTEPOCH= 1 CATEGORIES= lang parallel MASTER_SITES= http://www.erlang.org/download/ \ diff --git a/lang/erlang14/files/patch-erts_emulator_beam_utils.c b/lang/erlang14/files/patch-erts_emulator_beam_utils.c new file mode 100644 index 000000000000..58e675168a85 --- /dev/null +++ b/lang/erlang14/files/patch-erts_emulator_beam_utils.c @@ -0,0 +1,36 @@ + +$FreeBSD$ + +--- erts/emulator/beam/utils.c.orig ++++ erts/emulator/beam/utils.c +@@ -2999,15 +2999,16 @@ + static void + ptimer_timeout(ErtsSmpPTimer *ptimer) + { +- if (!(ptimer->timer.flags & ERTS_PTMR_FLG_CANCELLED)) { + if (is_internal_pid(ptimer->timer.id)) { + Process *p; +- p = erts_pid2proc(NULL, +- 0, +- ptimer->timer.id, +- ERTS_PROC_LOCK_MAIN|ERTS_PROC_LOCK_STATUS); ++ p = erts_pid2proc_opt(NULL, ++ 0, ++ ptimer->timer.id, ++ ERTS_PROC_LOCK_MAIN|ERTS_PROC_LOCK_STATUS, ++ ERTS_P2P_FLG_ALLOW_OTHER_X); + if (p) { +- if (!(ptimer->timer.flags & ERTS_PTMR_FLG_CANCELLED)) { ++ if (!p->is_exiting ++ && !(ptimer->timer.flags & ERTS_PTMR_FLG_CANCELLED)) { + ASSERT(*ptimer->timer.timer_ref == ptimer); + *ptimer->timer.timer_ref = NULL; + (*ptimer->timer.timeout_func)(p); +@@ -3028,7 +3029,6 @@ + erts_smp_io_unlock(); + } + } +- } + free_ptimer(ptimer); + } + |