* ChangeNotes: New file. Add entry cgf-000001.

* sigproc.cc (proc_terminate): Don't set parent pid of child to 1 if we've
execed since the execed process is still considered the parent.
* child_info.h: Bump copyright.
This commit is contained in:
Christopher Faylor
2012-05-02 16:39:39 +00:00
parent 03cd7bbbb1
commit b79c0094f8
4 changed files with 44 additions and 2 deletions

View File

@ -445,9 +445,17 @@ proc_terminate ()
/* Clean out proc processes from the pid list. */
for (int i = 0; i < nprocs; i++)
{
procs[i]->ppid = 1;
/* If we've execed then the execed process will handle setting ppid
to 1 iff it is a Cygwin process. */
if (!have_execed || !have_execed_cygwin)
procs[i]->ppid = 1;
if (procs[i].wait_thread)
procs[i].wait_thread->terminate_thread ();
/* Release memory associated with this process unless it is 'myself'.
'myself' is only in the procs table when we've execed. We reach
here when the next process has finished initializing but we still
can't free the memory used by 'myself' since it is used later on
during cygwin tear down. */
if (procs[i] != myself)
procs[i].release ();
}