From e014e52e7c0bab89204339f0dc98c110ae48715b Mon Sep 17 00:00:00 2001 From: bje Date: Fri, 24 Jul 1998 12:09:32 +0000 Subject: Minor #include and #ifdef fixes. --- ChangeLog | 5 ++--- create.c | 3 +++ pthread.h | 4 ++++ 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index a7109c8..e13ca49 100644 --- a/ChangeLog +++ b/ChangeLog @@ -10,10 +10,9 @@ * create.c: #include to get a prototype for memcpy(). (pthread_create): New threads inherit their creator's signal - mask. Copy the signal mask to the new thread structure. - + mask. Copy the signal mask to the new thread structure if we know + about signals. - Fri Jul 24 16:33:17 1998 Ross Johnson * fork.c (pthread_atfork): Add all the necessary push calls. diff --git a/create.c b/create.c index e8fd1c1..74d207d 100644 --- a/create.c +++ b/create.c @@ -86,7 +86,10 @@ pthread_create(pthread_t *thread, attr_copy->canceltype = attr->canceltype; attr_copy->detached = attr->detached; attr_copy->priority = attr->priority; + +#if HAVE_SIGSET_T memcpy(attr_copy.sigmask, attr.sigmask, sizeof(sigset_t)); +#endif /* HAVE_SIGSET_T */ } /* Start running, not suspended. */ diff --git a/pthread.h b/pthread.h index 43b9594..70ece60 100644 --- a/pthread.h +++ b/pthread.h @@ -22,6 +22,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef _PTHREADS_H #define _PTHREADS_H +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif /* HAVE_CONFIG_H */ + #ifdef HAVE_SIGNAL_H #include #endif /* HAVE_SIGNAL_H */ -- cgit v1.2.3