about summary refs log tree commit diff
path: root/posix
diff options
context:
space:
mode:
Diffstat (limited to 'posix')
-rw-r--r--posix/regex.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/posix/regex.c b/posix/regex.c
index e2d31a0427..26c876a155 100644
--- a/posix/regex.c
+++ b/posix/regex.c
@@ -49,8 +49,9 @@
 /* For platform which support the ISO C amendement 1 functionality we
    support user defined character classes.  */
 #if defined _LIBC || (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H)
-# include <wctype.h>
+/* Solaris 2.5 has a bug: <wchar.h> must be included before <wctype.h>.  */
 # include <wchar.h>
+# include <wctype.h>
 
 /* We have to keep the namespace clean.  */
 # define regfree(preg) __regfree (preg)