summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2000-01-31 08:27:51 +0000
committerJim Meyering <jim@meyering.net>2000-01-31 08:27:51 +0000
commit5b2acd8d30116e115745d25b3da98dc16f1e0037 (patch)
treec64fdb12fb3bcf991f6aeebe2c766522621aa7bf /lib
parent488aef730191a8acf4006d0ffdcfd9d1ee3a26fb (diff)
downloadcoreutils-5b2acd8d30116e115745d25b3da98dc16f1e0037.tar.xz
(ISASCII): Add #undef and move definition to follow
inclusion of wctype.h to work around solaris2.6 namespace pollution. (ISPRINT): Likewise.
Diffstat (limited to 'lib')
-rw-r--r--lib/quotearg.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/lib/quotearg.c b/lib/quotearg.c
index 722fa734d..47e4c1425 100644
--- a/lib/quotearg.c
+++ b/lib/quotearg.c
@@ -26,12 +26,6 @@
#include <xalloc.h>
#include <ctype.h>
-#if defined (STDC_HEADERS) || (!defined (isascii) && !defined (HAVE_ISASCII))
-# define ISASCII(c) 1
-#else
-# define ISASCII(c) isascii (c)
-#endif
-#define ISPRINT(c) (ISASCII (c) && isprint (c))
#if ENABLE_NLS
# include <libintl.h>
@@ -73,6 +67,17 @@
#define INT_BITS (sizeof (int) * CHAR_BIT)
+#if defined (STDC_HEADERS) || (!defined (isascii) && !defined (HAVE_ISASCII))
+/* Undefine to protect against the definition in wctype.h of solaris2.6. */
+# undef ISASCII
+# define ISASCII(c) 1
+#else
+# define ISASCII(c) isascii (c)
+#endif
+/* Undefine to protect against the definition in wctype.h of solaris2.6. */
+#undef ISASCII
+#define ISPRINT(c) (ISASCII (c) && isprint (c))
+
struct quoting_options
{
/* Basic quoting style. */