4
0
mirror of git://sourceware.org/git/newlib-cygwin.git synced 2025-01-19 12:59:21 +08:00
Corinna Vinschen 88605243a1 Cygwin: fix child getting another pid after spawnve
When calling spawnve, in contrast to execve, the parent has
to create the pid for the child.  With the old technique
this was simply the Windows pid, but now we have to inform
the child about its new pid.

Add a cygpid member to class child_info_spawn.  Set it in
child_info_spawn::worker, just prior to calling CreateProcess
rather than afterwards.  Overwrite cygheap->pid in
child_info_spawn::handle_spawn before calling pinfo::thisproc.
Make sure pinfo::thisproc knows the pid is already set by
setting the handle argument to INVALID_HANDLE_VALUE.

Also set procinfo->dwProcessId to myself_initial.dwProcessId
instead of to myself_initial.pid for clarity.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2019-02-08 15:49:47 +01:00
..
2016-11-24 16:09:31 +01:00
2016-06-25 00:43:01 +02:00
2019-01-15 22:02:33 +01:00
2019-01-15 22:02:33 +01:00
2019-01-15 22:02:33 +01:00
2019-01-15 22:02:33 +01:00
2018-02-20 17:59:53 +01:00
2015-03-03 12:58:34 +00:00
2015-11-18 19:09:47 +01:00
2017-03-27 22:03:58 +01:00
2018-08-07 14:51:10 +02:00
2018-08-07 14:51:10 +02:00
2015-08-17 11:05:43 +02:00
2018-04-16 22:46:11 -05:00
2018-02-07 13:07:44 +01:00
2019-01-15 22:02:33 +01:00
2019-01-13 23:13:33 +01:00
2016-06-23 16:56:41 +02:00