* DevNotes: Add entry cgf-000007.

* child_info.h (child_info_spawn::parent_winpid): Declare new field.
(child_info_spawn::get_parent_handle): Declare new function.
* dcrt0.cc (child_info_spawn::get_parent_handle): Define new function.
(child_info_spawn::handle_spawn): Recreate parent handle if possible when
dynamically loaded.  Don't mess with parent handle if it's NULL.
* spawn.cc (child_info_spawn::worker): Set parent_winpid appropriately.
This commit is contained in:
Christopher Faylor
2012-05-14 22:42:56 +00:00
parent 77009cee1e
commit 3de7be4c1d
6 changed files with 52 additions and 3 deletions

View File

@@ -1,3 +1,26 @@
2012-05-14 cgf-000007
<1.7.16>
- Fix invocation of strace from a cygwin process. Fixes:
http://cygwin.com/ml/cygwin/2012-05/msg00292.html
</1.7.16>
The change in cgf-000004 introduced a problem for processes which load
cygwin1.dll dynamically. strace.exe is the most prominent example of
this.
Since the parent handle is now closed for "non-Cygwin" processes, when
strace.exe tried to dynamically load cygwin1.dll, the handle was invalid
and child_info_spawn::handle_spawn couldn't use retrieve information
from the parent. This eventually led to a strace_printf error due to an
attempt to dereference an unavailable cygheap. Probably have to fix
this someday. You shouldn't use the cygheap while attempting to print
an error about the inavailability of said cygheap.
This was fixed by saving the parent pid in child_info_spawn and calling
OpenProcess for the parent pid and using that handle iff a process is
dynamically loaded.
2012-05-12 cgf-000006
<1.7.16>