diff options
author | bje <bje> | 1998-07-24 12:06:28 +0000 |
---|---|---|
committer | bje <bje> | 1998-07-24 12:06:28 +0000 |
commit | 44a56b7d9a229b18b9f9886888eb344ee3f1ff99 (patch) | |
tree | 7d04b7e2105cc9363746b1cb74babc33a54c2323 /create.c | |
parent | 21e7d43d69e592cf909e4ae66971fc387b3bfc3b (diff) |
1998-07-24 Ben Elliston <bje@cygnus.com>
* pthread.h (SIG_BLOCK): Define if not already defined.
(SIG_UNBLOCK): Likewise.
(SIG_SETMASK): Likewise.
(pthread_attr_t): Add signal mask member.
(pthread_sigmask): Add function prototype.
* signal.c (pthread_sigmask): Implement.
* create.c: #include <string.h> 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.
Diffstat (limited to 'create.c')
-rw-r--r-- | create.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -8,6 +8,8 @@ #include <windows.h> #include <process.h> +#include <string.h> + #include "pthread.h" #include "implement.h" @@ -84,6 +86,7 @@ pthread_create(pthread_t *thread, attr_copy->canceltype = attr->canceltype; attr_copy->detached = attr->detached; attr_copy->priority = attr->priority; + memcpy(attr_copy.sigmask, attr.sigmask, sizeof(sigset_t)); } /* Start running, not suspended. */ |