From e5700ea5607c366ff8c4fbf272749efae886bbab Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 12 Jul 2005 23:49:08 +0000 Subject: r8397: merged an upstream fix for the expression bug tpot found yesterday (This used to be commit 93712dd894b4ddaa2281034c754c0fa15f5ec34c) --- source4/lib/ejs/ejsLex.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source4') diff --git a/source4/lib/ejs/ejsLex.c b/source4/lib/ejs/ejsLex.c index 6dcc1c7b78..a5f15c2979 100644 --- a/source4/lib/ejs/ejsLex.c +++ b/source4/lib/ejs/ejsLex.c @@ -663,11 +663,11 @@ static int getLexicalToken(Ejs *ep, int state) break; } #if BLD_FEATURE_FLOATING_POINT - if (c == '.' || tolower(c) == 'e' || c == '+' || c == '-') { + if (c == '.' || tolower(c) == 'e' || tolower(c) == 'f') { type = MPR_TYPE_FLOAT; } - } while (isdigit(c) || c == '.' || tolower(c) == 'e' || - c == '+' || c == '-'); + } while (isdigit(c) || c == '.' || tolower(c) == 'e' || tolower(c) == 'f' || + ((type == MPR_TYPE_FLOAT) && (c == '+' || c == '-'))); #else } while (isdigit(c)); #endif -- cgit