diff options
author | Rickard Green <[email protected]> | 2016-09-14 13:20:53 +0200 |
---|---|---|
committer | Rickard Green <[email protected]> | 2016-09-14 13:20:53 +0200 |
commit | 25ea6279b55db5af53040ec4ce9bf73b4aeeaa16 (patch) | |
tree | e2dba45836e868199008c699e225f31a0237eeee /erts/emulator/beam | |
parent | 57513239dc265373521bc4f04c154f17d5f0bae9 (diff) | |
download | otp-25ea6279b55db5af53040ec4ce9bf73b4aeeaa16.tar.gz otp-25ea6279b55db5af53040ec4ce9bf73b4aeeaa16.tar.bz2 otp-25ea6279b55db5af53040ec4ce9bf73b4aeeaa16.zip |
Ensure we dont use an invalid live heap fragment pointer
Diffstat (limited to 'erts/emulator/beam')
-rw-r--r-- | erts/emulator/beam/erl_gc.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/erts/emulator/beam/erl_gc.c b/erts/emulator/beam/erl_gc.c index e2875cedb3..027ade45e5 100644 --- a/erts/emulator/beam/erl_gc.c +++ b/erts/emulator/beam/erl_gc.c @@ -388,6 +388,11 @@ erts_gc_after_bif_call_lhf(Process* p, ErlHeapFragment *live_hf_end, return result; } + if (!p->mbuf) { + /* Must have GC:d in BIF call... invalidate live_hf_end */ + live_hf_end = ERTS_INVALID_HFRAG_PTR; + } + if (is_non_value(result)) { if (p->freason == TRAP) { #if HIPE |