aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/erl_printf_term.c
diff options
context:
space:
mode:
authorStanislav Mayorov <[email protected]>2018-12-13 11:39:16 +0700
committerJohn Högberg <[email protected]>2019-01-10 09:39:29 +0100
commita56bc7180c639f1f08355f22e22cf539db16982c (patch)
tree5b9549f2cd5c5a9d10dead20c1c40f501dbfa185 /erts/emulator/beam/erl_printf_term.c
parent6120af3481f9deac2be1ff4bbb2684f24ef172eb (diff)
downloadotp-a56bc7180c639f1f08355f22e22cf539db16982c.tar.gz
otp-a56bc7180c639f1f08355f22e22cf539db16982c.tar.bz2
otp-a56bc7180c639f1f08355f22e22cf539db16982c.zip
Accept base in all integer-printing functions
Diffstat (limited to 'erts/emulator/beam/erl_printf_term.c')
-rw-r--r--erts/emulator/beam/erl_printf_term.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/erts/emulator/beam/erl_printf_term.c b/erts/emulator/beam/erl_printf_term.c
index 990a01b96f..9cfb7fc681 100644
--- a/erts/emulator/beam/erl_printf_term.c
+++ b/erts/emulator/beam/erl_printf_term.c
@@ -364,13 +364,13 @@ print_term(fmtfn_t fn, void* arg, Eterm obj, long *dcount) {
int print_res;
char def_buf[64];
char *buf, *big_str;
- Uint sz = (Uint) big_decimal_estimate(wobj);
+ Uint sz = (Uint) big_integer_estimate(wobj, 10);
sz++;
if (sz <= 64)
buf = &def_buf[0];
else
buf = erts_alloc(ERTS_ALC_T_TMP, sz);
- big_str = erts_big_to_string(wobj, buf, sz);
+ big_str = erts_big_to_string(wobj, 10, buf, sz);
print_res = erts_printf_string(fn, arg, big_str);
if (buf != &def_buf[0])
erts_free(ERTS_ALC_T_TMP, (void *) buf);