summaryrefslogtreecommitdiff
path: root/lib/nl_langinfo.c
diff options
context:
space:
mode:
authorClint Adams <clint@debian.org>2018-12-22 09:23:19 -0500
committerClint Adams <clint@debian.org>2018-12-22 09:23:19 -0500
commit637a2e292881341dde845545517b0ed3d3ccfc94 (patch)
treec0d05d9f8978af415c5cea9ec39fc85b6bfb6cec /lib/nl_langinfo.c
parent117dcd10d7e04d0dda7668518b8d085027f4d705 (diff)
New upstream version 4.7
Diffstat (limited to 'lib/nl_langinfo.c')
-rw-r--r--lib/nl_langinfo.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/nl_langinfo.c b/lib/nl_langinfo.c
index d98f034..ea26730 100644
--- a/lib/nl_langinfo.c
+++ b/lib/nl_langinfo.c
@@ -22,7 +22,7 @@
#include <locale.h>
#include <string.h>
-#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+#if defined _WIN32 && ! defined __CYGWIN__
# define WIN32_LEAN_AND_MEAN /* avoid including junk */
# include <windows.h>
# include <stdio.h>
@@ -65,7 +65,7 @@ ctype_codeset (void)
}
}
-# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+# if defined _WIN32 && ! defined __CYGWIN__
/* If setlocale is successful, it returns the number of the
codepage, as a string. Otherwise, fall back on Windows API
GetACP, which returns the locale's codepage as a number (although
@@ -191,8 +191,10 @@ nl_langinfo (nl_item item)
return localeconv () ->decimal_point;
case THOUSEP:
return localeconv () ->thousands_sep;
+# ifdef GROUPING
case GROUPING:
return localeconv () ->grouping;
+# endif
/* nl_langinfo items of the LC_TIME category.
TODO: Really use the locale. */
case D_T_FMT:
@@ -320,6 +322,7 @@ nl_langinfo (nl_item item)
/* nl_langinfo items of the LC_MONETARY category. */
case CRNCYSTR:
return localeconv () ->currency_symbol;
+# ifdef INT_CURR_SYMBOL
case INT_CURR_SYMBOL:
return localeconv () ->int_curr_symbol;
case MON_DECIMAL_POINT:
@@ -348,6 +351,7 @@ nl_langinfo (nl_item item)
return & localeconv () ->p_sign_posn;
case N_SIGN_POSN:
return & localeconv () ->n_sign_posn;
+# endif
/* nl_langinfo items of the LC_MESSAGES category
TODO: Really use the locale. */
case YESEXPR: