aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/beam_emu.c
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2014-09-04 20:10:54 +0200
committerSverker Eriksson <[email protected]>2014-09-04 20:17:59 +0200
commit2b53f2b1514b0d405ab92c767277483c761ad928 (patch)
tree614f9ccb33969eb17bd7bf59967854d276b90257 /erts/emulator/beam/beam_emu.c
parent35ff91189c8dd4ceed3d8f29536f500787ba4782 (diff)
downloadotp-2b53f2b1514b0d405ab92c767277483c761ad928.tar.gz
otp-2b53f2b1514b0d405ab92c767277483c761ad928.tar.bz2
otp-2b53f2b1514b0d405ab92c767277483c761ad928.zip
erts: Refactor binary allocation interface to also initialize Binary
except the reference counter 'refc', as different callers have different strategies regarding the lifetime of the binary.
Diffstat (limited to 'erts/emulator/beam/beam_emu.c')
-rw-r--r--erts/emulator/beam/beam_emu.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/erts/emulator/beam/beam_emu.c b/erts/emulator/beam/beam_emu.c
index 8bfb7d2ad2..32961da271 100644
--- a/erts/emulator/beam/beam_emu.c
+++ b/erts/emulator/beam/beam_emu.c
@@ -3782,8 +3782,6 @@ get_map_elements_fail:
* Allocate the binary struct itself.
*/
bptr = erts_bin_nrml_alloc(num_bytes);
- bptr->flags = 0;
- bptr->orig_size = num_bytes;
erts_refc_init(&bptr->refc, 1);
erts_current_bin = (byte *) bptr->orig_bytes;
@@ -3883,8 +3881,6 @@ get_map_elements_fail:
* Allocate the binary struct itself.
*/
bptr = erts_bin_nrml_alloc(tmp_arg1);
- bptr->flags = 0;
- bptr->orig_size = tmp_arg1;
erts_refc_init(&bptr->refc, 1);
erts_current_bin = (byte *) bptr->orig_bytes;