Index: main/snprintf.c =================================================================== RCS file: /repository/php-src/main/snprintf.c,v retrieving revision 1.37.2.4.2.7 diff -u -p -d -r1.37.2.4.2.7 snprintf.c --- main/snprintf.c 19 Dec 2006 13:27:09 -0000 1.37.2.4.2.7 +++ main/snprintf.c 19 Dec 2006 21:15:21 -0000 @@ -38,9 +38,6 @@ #ifdef HAVE_LOCALE_H #include -#define LCONV_DECIMAL_POINT (*lconv->decimal_point) -#else -#define LCONV_DECIMAL_POINT '.' #endif /* @@ -587,10 +584,6 @@ static int format_converter(register buf char num_buf[NUM_BUF_SIZE]; char char_buf[2]; /* for printing %% and % */ -#ifdef HAVE_LOCALE_H - struct lconv *lconv = NULL; -#endif - /* * Flag variables */ @@ -947,14 +940,9 @@ static int format_converter(register buf s = "INF"; s_len = 3; } else { -#ifdef HAVE_LOCALE_H - if (!lconv) { - lconv = localeconv(); - } -#endif s = php_conv_fp((*fmt == 'f')?'F':*fmt, fp_num, alternate_form, (adjust_precision == NO) ? FLOAT_DIGITS : precision, - (*fmt == 'f')?LCONV_DECIMAL_POINT:'.', + '.', &is_negative, &num_buf[1], &s_len); if (is_negative) prefix_char = '-'; @@ -1001,12 +989,7 @@ static int format_converter(register buf /* * * We use &num_buf[ 1 ], so that we have room for the sign */ -#ifdef HAVE_LOCALE_H - if (!lconv) { - lconv = localeconv(); - } -#endif - s = php_gcvt(fp_num, precision, LCONV_DECIMAL_POINT, (*fmt == 'G')?'E':'e', &num_buf[1]); + s = php_gcvt(fp_num, precision, '.', (*fmt == 'G')?'E':'e', &num_buf[1]); if (*s == '-') prefix_char = *s++; else if (print_sign) Index: main/spprintf.c =================================================================== RCS file: /repository/php-src/main/spprintf.c,v retrieving revision 1.25.2.2.2.4 diff -u -p -d -r1.25.2.2.2.4 spprintf.c --- main/spprintf.c 19 Dec 2006 13:13:28 -0000 1.25.2.2.2.4 +++ main/spprintf.c 19 Dec 2006 21:15:21 -0000 @@ -92,9 +92,6 @@ #ifdef HAVE_LOCALE_H #include -#define LCONV_DECIMAL_POINT (*lconv->decimal_point) -#else -#define LCONV_DECIMAL_POINT '.' #endif #include "snprintf.h" @@ -202,10 +199,6 @@ static void xbuf_format_converter(smart_ char num_buf[NUM_BUF_SIZE]; char char_buf[2]; /* for printing %% and % */ -#ifdef HAVE_LOCALE_H - struct lconv *lconv = NULL; -#endif - /* * Flag variables */ @@ -559,14 +552,9 @@ static void xbuf_format_converter(smart_ s = "inf"; s_len = 3; } else { -#ifdef HAVE_LOCALE_H - if (!lconv) { - lconv = localeconv(); - } -#endif s = php_conv_fp((*fmt == 'f')?'F':*fmt, fp_num, alternate_form, (adjust_precision == NO) ? FLOAT_DIGITS : precision, - (*fmt == 'f')?(*lconv->decimal_point):'.', + '.', &is_negative, &num_buf[1], &s_len); if (is_negative) prefix_char = '-'; @@ -613,12 +601,7 @@ static void xbuf_format_converter(smart_ /* * * We use &num_buf[ 1 ], so that we have room for the sign */ -#ifdef HAVE_LOCALE_H - if (!lconv) { - lconv = localeconv(); - } -#endif - s = php_gcvt(fp_num, precision, *lconv->decimal_point, (*fmt == 'G')?'E':'e', &num_buf[1]); + s = php_gcvt(fp_num, precision, '.', (*fmt == 'G')?'E':'e', &num_buf[1]); if (*s == '-') prefix_char = *s++; else if (print_sign)