diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2015-01-19 17:42:04 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2015-01-19 17:42:04 +0000 |
commit | c95ce0216000cb8fb85d666adc79ed62b126d2ec (patch) | |
tree | fcda9cd0c5f668aeee320f3470904347262caaa2 /winsup/cygwin/cygserver_ipc.h | |
parent | 70e52cba1b27fe65dc743b44bb73dc1a5c718bbe (diff) | |
download | cygnal-c95ce0216000cb8fb85d666adc79ed62b126d2ec.tar.gz cygnal-c95ce0216000cb8fb85d666adc79ed62b126d2ec.tar.bz2 cygnal-c95ce0216000cb8fb85d666adc79ed62b126d2ec.zip |
* cygserver_ipc.h (ipc_retval): Add default constructor.
(class thread): struct->class. Add prototypes for new private methods
dup_signal_arrived and close_signal_arrived. Implement constructor and
destructor.
Diffstat (limited to 'winsup/cygwin/cygserver_ipc.h')
-rw-r--r-- | winsup/cygwin/cygserver_ipc.h | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/winsup/cygwin/cygserver_ipc.h b/winsup/cygwin/cygserver_ipc.h index 52f9f5ddd..14495bc94 100644 --- a/winsup/cygwin/cygserver_ipc.h +++ b/winsup/cygwin/cygserver_ipc.h @@ -1,6 +1,6 @@ /* cygserver_ipc.h - Copyright 2002, 2003, 2004, 2012, 2013, 2014 Red Hat, Inc. + Copyright 2002, 2003, 2004, 2012, 2013, 2014, 2015 Red Hat, Inc. This file is part of Cygwin. @@ -62,6 +62,7 @@ private: }; public: + ipc_retval () { ssz = 0; } ipc_retval (ssize_t nssz) { ssz = nssz; } operator int () const { return i; } @@ -84,10 +85,23 @@ public: vm_object_t operator = (vm_object_t nobj) { return obj = nobj; } }; -struct thread { +class thread { +private: + /* Implemented in cgyserver/process.cc */ + void dup_signal_arrived (); + void close_signal_arrived (); +public: class process *client; proc *ipcblk; ipc_retval td_retval[2]; + + thread (class process *_client, proc *_proc, bool _init_m1) + : client (_client), ipcblk (_proc) + { + td_retval[0] = td_retval[1] = _init_m1 ? -1 : 0; + dup_signal_arrived (); + } + ~thread () { close_signal_arrived (); } }; #define td_proc ipcblk #define p_pid cygpid |