aboutsummaryrefslogtreecommitdiffstats
path: root/erts
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2014-10-28 19:17:21 +0100
committerSverker Eriksson <[email protected]>2014-10-28 19:17:21 +0100
commit3f449580f2f890815f165781f1184541b0672f77 (patch)
treefa75219870209cd627769f5cb9cc66f588f40ec9 /erts
parent6e30d2a47c2a2bded04b2a411161147cba7aca51 (diff)
parentff7739cfae9c2b0915842572284a702d52b2d8db (diff)
downloadotp-3f449580f2f890815f165781f1184541b0672f77.tar.gz
otp-3f449580f2f890815f165781f1184541b0672f77.tar.bz2
otp-3f449580f2f890815f165781f1184541b0672f77.zip
Merge branch 'maint'
Diffstat (limited to 'erts')
-rw-r--r--erts/emulator/beam/erl_alloc_util.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/erts/emulator/beam/erl_alloc_util.c b/erts/emulator/beam/erl_alloc_util.c
index a4e164bf51..55052430e1 100644
--- a/erts/emulator/beam/erl_alloc_util.c
+++ b/erts/emulator/beam/erl_alloc_util.c
@@ -1775,6 +1775,18 @@ handle_delayed_dealloc(Allctr_t *allctr,
* data has been overwritten by the queue.
*/
Carrier_t *crr = FIRST_BLK_TO_MBC(allctr, blk);
+
+ /* Restore word overwritten by the dd-queue as it will be read
+ * if this carrier is pulled from dc_list by cpool_fetch()
+ */
+ ERTS_ALC_CPOOL_ASSERT(FBLK_TO_MBC(blk) != crr);
+ ERTS_ALC_CPOOL_ASSERT(sizeof(ErtsAllctrDDBlock_t) == sizeof(void*));
+#ifdef MBC_ABLK_OFFSET_BITS
+ blk->u.carrier = crr;
+#else
+ blk->carrier = crr;
+#endif
+
ERTS_ALC_CPOOL_ASSERT(ERTS_ALC_IS_CPOOL_ENABLED(allctr));
ERTS_ALC_CPOOL_ASSERT(allctr == crr->cpool.orig_allctr);
ERTS_ALC_CPOOL_ASSERT(((erts_aint_t) allctr)