From 35602d41062400066eb3525cf31a4e8c5acb6926 Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Wed, 19 Sep 2007 17:52:40 +0200 Subject: [PATCH] msvcrt: Added implementation for __STRINGTOLD. --- dlls/msvcrt/msvcrt.spec | 2 +- dlls/msvcrt/string.c | 16 +++++++++++++++- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/dlls/msvcrt/msvcrt.spec b/dlls/msvcrt/msvcrt.spec index 559124f59d9..e92b0742e1f 100644 --- a/dlls/msvcrt/msvcrt.spec +++ b/dlls/msvcrt/msvcrt.spec @@ -80,7 +80,7 @@ @ cdecl __RTCastToVoid(ptr) MSVCRT___RTCastToVoid @ cdecl __RTDynamicCast(ptr long ptr ptr long) MSVCRT___RTDynamicCast @ cdecl __RTtypeid(ptr) MSVCRT___RTtypeid -@ stub __STRINGTOLD #(ptr ptr str long) +@ cdecl __STRINGTOLD(ptr ptr str long) @ extern __argc MSVCRT___argc @ extern __argv MSVCRT___argv @ extern __badioinfo MSVCRT___badioinfo diff --git a/dlls/msvcrt/string.c b/dlls/msvcrt/string.c index ffacc35a1ae..5fc71468eb0 100644 --- a/dlls/msvcrt/string.c +++ b/dlls/msvcrt/string.c @@ -174,7 +174,7 @@ int CDECL MSVCRT__stricoll( const char* str1, const char* str2 ) /******************************************************************** * _atoldbl (MSVCRT.@) */ -int CDECL MSVCRT__atoldbl(MSVCRT__LDOUBLE * value, char * str) +int CDECL MSVCRT__atoldbl(MSVCRT__LDOUBLE *value, const char *str) { /* FIXME needs error checking for huge/small values */ #ifdef HAVE_STRTOLD @@ -185,3 +185,17 @@ int CDECL MSVCRT__atoldbl(MSVCRT__LDOUBLE * value, char * str) #endif return 0; } + +/******************************************************************** + * __STRINGTOLD (MSVCRT.@) + */ +int CDECL __STRINGTOLD( MSVCRT__LDOUBLE *value, char **endptr, const char *str, int flags ) +{ +#ifdef HAVE_STRTOLD + FIXME("%p %p %s %x partial stub\n", value, endptr, str, flags ); + value->x = strtold(str,endptr); +#else + FIXME("%p %p %s %x stub\n", value, endptr, str, flags ); +#endif + return 0; +}