c_locale.cc (__convert_to_v): Prefer strtold_l over __strtold_l if available.
* config/locale/gnu/c_locale.cc (__convert_to_v): Prefer strtold_l over __strtold_l if available. From-SVN: r118654
This commit is contained in:
parent
9ff5780962
commit
29520adf7d
@ -1,3 +1,8 @@
|
||||
2006-11-10 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
* config/locale/gnu/c_locale.cc (__convert_to_v): Prefer
|
||||
strtold_l over __strtold_l if available.
|
||||
|
||||
2006-11-07 Benjamin Kosnik <bkoz@redhat.com>
|
||||
|
||||
PR libstdc++/29722
|
||||
|
@ -77,7 +77,13 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
|
||||
{
|
||||
char* __sanity;
|
||||
errno = 0;
|
||||
#if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
|
||||
// Prefer strtold_l, as __strtold_l isn't prototyped in more recent
|
||||
// glibc versions.
|
||||
long double __ld = strtold_l(__s, &__sanity, __cloc);
|
||||
#else
|
||||
long double __ld = __strtold_l(__s, &__sanity, __cloc);
|
||||
#endif
|
||||
if (__sanity != __s && errno != ERANGE)
|
||||
__v = __ld;
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user