From 9915dd03b432664c15ce4d1a1b8a019aee53c739 Mon Sep 17 00:00:00 2001 From: Piotr Caban Date: Thu, 22 Jul 2010 12:35:08 +0200 Subject: [PATCH] msvcrt: Fixed strtod_l/wcstod_l implementation. --- dlls/msvcrt/string.c | 5 ++++- dlls/msvcrt/tests/string.c | 5 +++++ dlls/msvcrt/wcs.c | 5 ++++- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/dlls/msvcrt/string.c b/dlls/msvcrt/string.c index 8c993992223..f44e6ebf7e9 100644 --- a/dlls/msvcrt/string.c +++ b/dlls/msvcrt/string.c @@ -169,6 +169,7 @@ double CDECL MSVCRT_strtod_l( const char *str, char **end, MSVCRT__locale_t loca int exp=0, sign=1; const char *p; double ret; + BOOL found_digit = FALSE; if(!str) { MSVCRT__invalid_parameter(NULL, NULL, NULL, 0, 0); @@ -191,6 +192,7 @@ double CDECL MSVCRT_strtod_l( const char *str, char **end, MSVCRT__locale_t loca p++; while(isdigit(*p)) { + found_digit = TRUE; hlp = d*10+*(p++)-'0'; if(d>MSVCRT_UI64_MAX/10 || hlpMSVCRT_UI64_MAX/10 || hlpMSVCRT_UI64_MAX/10 || hlpMSVCRT_UI64_MAX/10 || hlp