aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/binary.c
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2014-09-17 20:49:22 +0200
committerSverker Eriksson <[email protected]>2014-09-17 20:49:22 +0200
commit86b7cf42011302a78cb73ec4f339a2b31af8ae9a (patch)
treeed946bbce166d1c012788522f5508ec01fa006a2 /erts/emulator/beam/binary.c
parent723fea8f585c3006aa5cbda7d33de44d054eeafa (diff)
parent933a5f071e0dc7f2051e1ccc58ca4e361db52ef4 (diff)
downloadotp-86b7cf42011302a78cb73ec4f339a2b31af8ae9a.tar.gz
otp-86b7cf42011302a78cb73ec4f339a2b31af8ae9a.tar.bz2
otp-86b7cf42011302a78cb73ec4f339a2b31af8ae9a.zip
Merge branch 'sverk/bin-alloc-refactor'
* sverk/bin-alloc-refactor: erts: Fix gdb command etp-carrier-blocks for 32-bit erts: Refactor binary allocation interface to also initialize Binary
Diffstat (limited to 'erts/emulator/beam/binary.c')
-rw-r--r--erts/emulator/beam/binary.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/erts/emulator/beam/binary.c b/erts/emulator/beam/binary.c
index f50d484576..b014bca108 100644
--- a/erts/emulator/beam/binary.c
+++ b/erts/emulator/beam/binary.c
@@ -83,8 +83,6 @@ new_binary(Process *p, byte *buf, Uint len)
* Allocate the binary struct itself.
*/
bptr = erts_bin_nrml_alloc(len);
- bptr->flags = 0;
- bptr->orig_size = len;
erts_refc_init(&bptr->refc, 1);
if (buf != NULL) {
sys_memcpy(bptr->orig_bytes, buf, len);
@@ -122,8 +120,6 @@ Eterm erts_new_mso_binary(Process *p, byte *buf, int len)
* Allocate the binary struct itself.
*/
bptr = erts_bin_nrml_alloc(len);
- bptr->flags = 0;
- bptr->orig_size = len;
erts_refc_init(&bptr->refc, 1);
if (buf != NULL) {
sys_memcpy(bptr->orig_bytes, buf, len);
@@ -177,7 +173,6 @@ erts_realloc_binary(Eterm bin, size_t size)
} else { /* REFC */
ProcBin* pb = (ProcBin *) bval;
Binary* newbin = erts_bin_realloc(pb->val, size);
- newbin->orig_size = size;
pb->val = newbin;
pb->size = size;
pb->bytes = (byte*) newbin->orig_bytes;