Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2011-11-04 21:07:21 +0400
committerChristopher Faylor <me@cgf.cx>2011-11-04 21:07:21 +0400
commit26601df44c0d70a74e882f7ca0262220d1e9c382 (patch)
tree64391c16531790927f9f6e611a57daf2773adabe /winsup/cygwin/pinfo.h
parent705d704153cf2352205b7f481473971f9eda8073 (diff)
* pinfo.h (pinfo::reattach): Only set destroy to false when proc_subproc
succeeds. Return true for success. * sigproc.cc (child_info_spawn::reattach_children): Try harder to clean up on error by detecting reattach failures too.
Diffstat (limited to 'winsup/cygwin/pinfo.h')
-rw-r--r--winsup/cygwin/pinfo.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/winsup/cygwin/pinfo.h b/winsup/cygwin/pinfo.h
index f9e859cde..a69316148 100644
--- a/winsup/cygwin/pinfo.h
+++ b/winsup/cygwin/pinfo.h
@@ -175,10 +175,11 @@ public:
#ifndef _SIGPROC_H
int remember () {system_printf ("remember is not here"); return 0;}
#else
- void reattach ()
+ int reattach ()
{
- proc_subproc (PROC_REATTACH_CHILD, (DWORD) this);
- destroy = false;
+ int res = proc_subproc (PROC_REATTACH_CHILD, (DWORD) this);
+ destroy = res ? false : true;
+ return res;
}
int remember (bool detach)
{