mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-11-23 19:19:58 +08:00
Use wcstod_l on NetBSD
It has wcstod_l, but not uselocale, so we can't use the fallback.
This commit is contained in:
parent
f90cb3957f
commit
c66b3128ec
|
@ -389,7 +389,7 @@ int flock(int fd, int op) {
|
|||
|
||||
#endif // HAVE_FLOCK
|
||||
|
||||
#ifndef HAVE_WCSTOD_L
|
||||
#if !defined(HAVE_WCSTOD_L) && !defined(__NetBSD__)
|
||||
#undef wcstod_l
|
||||
// For platforms without wcstod_l C extension, wrap wcstod after changing the
|
||||
// thread-specific locale.
|
||||
|
|
|
@ -199,7 +199,10 @@ int flock(int fd, int op);
|
|||
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_WCSTOD_L
|
||||
// NetBSD _has_ wcstod_l, but it's doing some weak linking hullabaloo that I don't get.
|
||||
// Since it doesn't have uselocale (yes, the standard function isn't there, the non-standard extension is),
|
||||
// we can't try to use the fallback.
|
||||
#if !defined(HAVE_WCSTOD_L) && !defined(__NetBSD__)
|
||||
// On some platforms if this is incorrectly detected and a system-defined
|
||||
// defined version of `wcstod_l` exists, calling `wcstod` from our own
|
||||
// `wcstod_l` can call back into `wcstod_l` causing infinite recursion.
|
||||
|
|
Loading…
Reference in New Issue
Block a user