Allow exponents of zero (like "1.000E0") to parse

correctly. Previously, they caused DISP_E_TYPEMISMATCH.
This commit is contained in:
Walt Ogburn 2004-10-11 20:53:29 +00:00 committed by Alexandre Julliard
parent 1da3b41093
commit d5cf83317e
1 changed files with 2 additions and 2 deletions

View File

@ -1668,14 +1668,14 @@ HRESULT WINAPI VarParseNumFromStr(OLECHAR *lpszStr, LCID lcid, ULONG dwFlags,
int exponentSize = 0;
if (dwState & B_EXPONENT_START)
{
if (!isdigitW(*lpszStr))
break; /* No exponent digits - invalid */
while (*lpszStr == '0')
{
/* Skip leading zero's in the exponent */
cchUsed++;
lpszStr++;
}
if (!isdigitW(*lpszStr))
break; /* No exponent digits - invalid */
}
while (isdigitW(*lpszStr))