summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2016-10-12 13:31:07 (GMT)
committerdgp <dgp@users.sourceforge.net>2016-10-12 13:31:07 (GMT)
commitbd297e53d9c852c7011018a23ac73ecd1ab0a76a (patch)
tree4e8cab765b335af6a0fd1cd13fb3c89dfe2a0215
parent2b3a9ba90da9d322fea0de66b8c59427a69b4ec2 (diff)
downloadtcl-bd297e53d9c852c7011018a23ac73ecd1ab0a76a.zip
tcl-bd297e53d9c852c7011018a23ac73ecd1ab0a76a.tar.gz
tcl-bd297e53d9c852c7011018a23ac73ecd1ab0a76a.tar.bz2
[be003d570f] TclParseNumber() failed to fully implement TCL_PARSE_OCTAL_ONLY.
-rw-r--r--generic/tclStrToD.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/generic/tclStrToD.c b/generic/tclStrToD.c
index d05fe5d..b89ce45 100644
--- a/generic/tclStrToD.c
+++ b/generic/tclStrToD.c
@@ -589,6 +589,9 @@ TclParseNumber(
acceptPoint = p;
acceptLen = len;
if (c == 'x' || c == 'X') {
+ if (flags & TCL_PARSE_OCTAL_ONLY) {
+ goto endgame;
+ }
state = ZERO_X;
break;
}
@@ -599,6 +602,9 @@ TclParseNumber(
goto zeroo;
}
if (c == 'b' || c == 'B') {
+ if (flags & TCL_PARSE_OCTAL_ONLY) {
+ goto endgame;
+ }
state = ZERO_B;
break;
}