changeset 15432:6bebbb324858

pthread_sigmask: ensure usleep is declared * lib/pthread_sigmask.c [PTHREAD_SIGMASK_UNBLOCK_BUG]: Include <unistd.h>, to declare usleep. Needed on Solaris 8,
author Paul Eggert <eggert@cs.ucla.edu>
date Sat, 16 Jul 2011 02:01:17 -0700
parents 0d6da34844b5
children 2b7d01b95963
files ChangeLog lib/pthread_sigmask.c
diffstat 2 files changed, 10 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2011-07-16  Paul Eggert  <eggert@cs.ucla.edu>
+
+	pthread_sigmask: ensure usleep is declared
+	* lib/pthread_sigmask.c [PTHREAD_SIGMASK_UNBLOCK_BUG]:
+	Include <unistd.h>, to declare usleep.  Needed on Solaris 8,
+
 2011-07-15  Paul Eggert  <eggert@cs.ucla.edu>
 
 	doc: Document NonStop portability issues.
--- a/lib/pthread_sigmask.c
+++ b/lib/pthread_sigmask.c
@@ -22,6 +22,10 @@
 #include <errno.h>
 #include <stddef.h>
 
+#if PTHREAD_SIGMASK_UNBLOCK_BUG
+# include <unistd.h>
+#endif
+
 int
 pthread_sigmask (int how, const sigset_t *new_mask, sigset_t *old_mask)
 #undef pthread_sigmask