[GDB] Handle kill and detach packets.

This commit also includes a test to ensure that single stepping works,
since continue, kill, detach, and single step all share code.
This commit is contained in:
Stefan Hajnoczi
2008-06-05 15:31:48 +01:00
committed by Michael Brown
parent 27731d975e
commit 59b5465b30
3 changed files with 19 additions and 5 deletions

View File

@@ -235,11 +235,14 @@ static void gdbstub_rx_packet ( struct gdbstub *stub ) {
case 'M':
gdbstub_write_mem ( stub );
break;
case 'c':
gdbstub_continue ( stub, 0 );
break;
case 's':
gdbstub_continue ( stub, 1 );
case 'c': /* Continue */
case 'k': /* Kill */
case 's': /* Step */
case 'D': /* Detach */
gdbstub_continue ( stub, stub->payload [ 0 ] == 's' );
if ( stub->payload [ 0 ] == 'D' ) {
gdbstub_send_ok ( stub );
}
break;
default:
stub->len = 0;