diff options
author | Christopher Faylor <me@cgf.cx> | 2005-09-26 17:47:27 +0400 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2005-09-26 17:47:27 +0400 |
commit | 683cc8189ce70bb5f33bec465eebad6effc9bd36 (patch) | |
tree | b2b547e7fa04f0beaeff2bd67bf26ebbabd4db94 /winsup/cygwin | |
parent | f086715060bca513b83f3625b2193466acb1a940 (diff) |
* pinfo.cc (proc_waiter): Properly fill out si_code as according to SUSv3.
* exceptions.cc (handle_exceptions): Properly fill out si_code as according to
SUSv3.
Diffstat (limited to 'winsup/cygwin')
-rw-r--r-- | winsup/cygwin/ChangeLog | 7 | ||||
-rw-r--r-- | winsup/cygwin/pinfo.cc | 10 |
2 files changed, 11 insertions, 6 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 433119463..4fc427ebe 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,6 +1,11 @@ 2005-09-26 Christopher Faylor <cgf@timesys.com> - * exceptions.cc (handle_exceptions): Properly fill out si_code. + * pinfo.cc (proc_waiter): Properly fill out si_code as according to SUSv3. + +2005-09-26 Christopher Faylor <cgf@timesys.com> + + * exceptions.cc (handle_exceptions): Properly fill out si_code as + according to SUSv3. 2005-09-25 Christopher Faylor <cgf@timesys.com> diff --git a/winsup/cygwin/pinfo.cc b/winsup/cygwin/pinfo.cc index e4f773c39..2cceb951e 100644 --- a/winsup/cygwin/pinfo.cc +++ b/winsup/cygwin/pinfo.cc @@ -939,7 +939,7 @@ proc_waiter (void *arg) siginfo_t si; si.si_signo = SIGCHLD; - si.si_code = SI_KERNEL; + si.si_code = CLD_EXITED; si.si_pid = vchild->pid; si.si_errno = 0; #if 0 // FIXME: This is tricky to get right @@ -975,11 +975,11 @@ proc_waiter (void *arg) vchild.rd_proc_pipe = NULL; vchild.maybe_set_exit_code_from_windows (); if (WIFEXITED (vchild->exitcode)) - si.si_sigval.sival_int = CLD_EXITED; + si.si_code = CLD_EXITED; else if (WCOREDUMP (vchild->exitcode)) - si.si_sigval.sival_int = CLD_DUMPED; + si.si_code = CLD_DUMPED; else - si.si_sigval.sival_int = CLD_KILLED; + si.si_code = CLD_KILLED; si.si_status = vchild->exitcode; vchild->process_state = PID_EXITED; /* This should always be last. Do not use vchild-> beyond this point */ @@ -991,7 +991,7 @@ proc_waiter (void *arg) if (ISSTATE (myself, PID_NOCLDSTOP)) // FIXME: No need for this flag to be in _pinfo any longer continue; /* Child stopped. Signal myself. */ - si.si_sigval.sival_int = CLD_STOPPED; + si.si_code = CLD_STOPPED; break; case SIGCONT: continue; |