diff options
author | Hannes Domani <ssbssa@yahoo.de> | 2020-02-08 19:08:40 +0100 |
---|---|---|
committer | Hannes Domani <ssbssa@yahoo.de> | 2020-02-12 17:11:45 +0100 |
commit | 052793ad150643bd6cc34b02fc2a4fa0f5ec6428 (patch) | |
tree | fc5c14660728223f3e20b9844f9e3119a6090b68 /gdbserver | |
parent | cd5900f33b5bbd53a628071e4e7ab0d46af735ee (diff) | |
download | gdb-052793ad150643bd6cc34b02fc2a4fa0f5ec6428.zip gdb-052793ad150643bd6cc34b02fc2a4fa0f5ec6428.tar.gz gdb-052793ad150643bd6cc34b02fc2a4fa0f5ec6428.tar.bz2 |
Fix kill of processes created by win32_create_inferior
handle_v_kill uses signal_pid because win32 doesn't support multi-process.
Without this gdb just refuses to kill the process:
(gdb) kill
Kill the program being debugged? (y or n) y
Sending packet: $vKill;a410#33...Packet received: E01
Packet vKill (kill) is supported
Can't kill process
gdbserver/ChangeLog:
2020-02-12 Hannes Domani <ssbssa@yahoo.de>
* win32-low.c (win32_create_inferior): Set signal_pid.
Diffstat (limited to 'gdbserver')
-rw-r--r-- | gdbserver/ChangeLog | 4 | ||||
-rw-r--r-- | gdbserver/win32-low.c | 3 |
2 files changed, 7 insertions, 0 deletions
diff --git a/gdbserver/ChangeLog b/gdbserver/ChangeLog index 709ef23..1f930c4 100644 --- a/gdbserver/ChangeLog +++ b/gdbserver/ChangeLog @@ -1,3 +1,7 @@ +2020-02-12 Hannes Domani <ssbssa@yahoo.de> + + * win32-low.c (win32_create_inferior): Set signal_pid. + 2020-02-12 Maciej W. Rozycki <macro@wdc.com> Pedro Alves <palves@redhat.com> diff --git a/gdbserver/win32-low.c b/gdbserver/win32-low.c index 9d03437..557c90d 100644 --- a/gdbserver/win32-low.c +++ b/gdbserver/win32-low.c @@ -709,6 +709,9 @@ win32_create_inferior (const char *program, (assuming success). */ cs.last_ptid = win32_wait (ptid_t (current_process_id), &cs.last_status, 0); + /* Necessary for handle_v_kill. */ + signal_pid = current_process_id; + return current_process_id; } |