diff options
author | Christopher Faylor <me@cgf.cx> | 2002-08-06 05:08:55 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2002-08-06 05:08:55 +0000 |
commit | 1524ae42cf8595fd9a31084382ade0ff17172626 (patch) | |
tree | ede26f12347598e90e3f481198a5f35b6fe0c647 /winsup/cygwin/sigproc.cc | |
parent | ffebb4fe0c3e1c3ca5ab14ec7737da054e2dc096 (diff) | |
download | cygnal-1524ae42cf8595fd9a31084382ade0ff17172626.tar.gz cygnal-1524ae42cf8595fd9a31084382ade0ff17172626.tar.bz2 cygnal-1524ae42cf8595fd9a31084382ade0ff17172626.zip |
* cygthread.cc (cygthread::stub): Accept flag to pass info structure to thread
function.
(cygthread::operator new): Add defense debugging output.
(cygthread::cygthread): Add debugging output. Set name after thread has been
awakened to avoid a race.
(cygthread::exit_thread): Use handle operator rather than using ev directly.
(cygthread::exit_thread): Reorganize to provide debugging. Set __name to NULL.
* cygthread.h (cygself): Define.
* fhandler_tty.cc (fhandler_tty_master::init): Use cygself as argument so that
invoked thread can access its own info.
(process_output): Derive cygthread info of thread from thread argument.
* sigproc.cc (sigproc_init): Use cygself as argument so that invoked thread can
access its own info.
(wait_sig): Derive cygthread info of thread from thread argument.
Diffstat (limited to 'winsup/cygwin/sigproc.cc')
-rw-r--r-- | winsup/cygwin/sigproc.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/winsup/cygwin/sigproc.cc b/winsup/cygwin/sigproc.cc index 49947840e..96ba45a5b 100644 --- a/winsup/cygwin/sigproc.cc +++ b/winsup/cygwin/sigproc.cc @@ -571,7 +571,7 @@ sigproc_init () signal_arrived = CreateEvent(&sec_none_nih, TRUE, FALSE, NULL); ProtectHandle (signal_arrived); - hwait_sig = new cygthread (wait_sig, NULL, "sig"); + hwait_sig = new cygthread (wait_sig, cygself, "sig"); /* sync_proc_subproc is used by proc_subproc. It serialises * access to the children and zombie arrays. @@ -1030,10 +1030,10 @@ stopped_or_terminated (waitq *parent_w, _pinfo *child) * has been handled, as per POSIX. */ static DWORD WINAPI -wait_sig (VOID *) +wait_sig (VOID *self) { /* Initialization */ - (void) SetThreadPriority (*hwait_sig, WAIT_SIG_PRIORITY); + (void) SetThreadPriority (*((cygthread *) self), WAIT_SIG_PRIORITY); /* sigcatch_nosync - semaphore incremented by sig_dispatch_pending and * by foreign processes to force an examination of |