summaryrefslogtreecommitdiff
path: root/gutf8.c
diff options
context:
space:
mode:
authorOwen Taylor <otaylor@redhat.com>2000-07-03 22:01:58 +0000
committerOwen Taylor <otaylor@src.gnome.org>2000-07-03 22:01:58 +0000
commit960868332881b9ca1dc94baafa8aa42c07df3101 (patch)
tree626a33095ff865eb1fda42ab6f17a879830b4445 /gutf8.c
parent8384a1342edda081d962f934838d1a4dc347a72c (diff)
downloadglib-960868332881b9ca1dc94baafa8aa42c07df3101.tar.gz
Fix up to correspond to configure.in checks.
Mon Jul 3 17:58:02 2000 Owen Taylor <otaylor@redhat.com> * gutf8.c (g_utf8_get_charset_internal): Fix up to correspond to configure.in checks.
Diffstat (limited to 'gutf8.c')
-rw-r--r--gutf8.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/gutf8.c b/gutf8.c
index da5364cc6..3220d3de3 100644
--- a/gutf8.c
+++ b/gutf8.c
@@ -22,7 +22,7 @@
#include <config.h>
#include <stdlib.h>
-#ifdef HAVE_LANGINFO_H
+#ifdef HAVE_CODESET
#include <langinfo.h>
#endif
#include <string.h>
@@ -297,8 +297,8 @@ g_utf8_get_charset_internal (char **a)
if (charset && strstr (charset, "UTF-8"))
return TRUE;
-#ifdef _NL_CTYPE_CODESET_NAME
- charset = nl_langinfo (_NL_CTYPE_CODESET_NAME);
+#ifdef HAVE_CODESET
+ charset = nl_langinfo(CODESET);
if (charset)
{
if (a && ! *a)
@@ -306,8 +306,10 @@ g_utf8_get_charset_internal (char **a)
if (strcmp (charset, "UTF-8") == 0)
return TRUE;
}
-#elif CODESET
- charset = nl_langinfo(CODESET);
+#endif
+
+#if 0 /* #ifdef _NL_CTYPE_CODESET_NAME */
+ charset = nl_langinfo (_NL_CTYPE_CODESET_NAME);
if (charset)
{
if (a && ! *a)
@@ -315,7 +317,7 @@ g_utf8_get_charset_internal (char **a)
if (strcmp (charset, "UTF-8") == 0)
return TRUE;
}
-#endif
+#endif
if (a && ! *a)
*a = "US-ASCII";