From 88b886e6034b1902c929eb6e6e2a06b9f4854c03 Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Mon, 4 Sep 2000 15:52:16 +0000 Subject: 12741: outputradix was stomped on by nested matheval --- ChangeLog | 5 +++++ Src/math.c | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 16229693f..2ef9f20d5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2000-09-04 Peter Stephenson + + * 12741: Src/math.c: problem with nested matheval unexpectedly + stomping on outputradix. + 2000-09-04 Andrej Borsenkow * 12736: configure.in: Fix `make install' dependency diff --git a/Src/math.c b/Src/math.c index 77c7df2a5..282622f73 100644 --- a/Src/math.c +++ b/Src/math.c @@ -959,7 +959,9 @@ matheval(char *s) char *junk; mnumber x; int xmtok = mtok; - outputradix = 0; + /* maintain outputradix across levels of evaluation */ + if (!mlevel) + outputradix = 0; if (!*s) { x.type = MN_INTEGER; -- cgit 1.4.1