]> git.saurik.com Git - apple/libc.git/blame - gdtoa/FreeBSD/machdep_ldisx.c.patch
Libc-391.2.3.tar.gz
[apple/libc.git] / gdtoa / FreeBSD / machdep_ldisx.c.patch
CommitLineData
3d9156a7
A
1--- machdep_ldisx.c.orig 2003-05-20 15:20:48.000000000 -0700
2+++ machdep_ldisx.c 2005-02-17 02:00:41.000000000 -0800
3@@ -33,6 +33,8 @@
4 #include <sys/cdefs.h>
5 __FBSDID("$FreeBSD: src/lib/libc/gdtoa/machdep_ldisx.c,v 1.2 2003/04/09 05:58:43 das Exp $");
6
7+#include "xlocale_private.h"
8+
9 #include "gdtoaimp.h"
10
11 long double
12@@ -40,6 +42,16 @@
13 {
14 long double result;
15
16- strtopx(s, sp, &result);
17+ strtopx(s, sp, &result, __current_locale());
18+ return result;
19+}
20+
21+long double
22+strtold_l(const char * __restrict s, char ** __restrict sp, locale_t loc)
23+{
24+ long double result;
25+
26+ NORMALIZE_LOCALE(loc);
27+ strtopx(s, sp, &result, loc);
28 return result;
29 }