Commit bbeb7b5cbd312b4690843499e0061691b8ae1fd8
1 parent
f9ebe432
SIGINT generation (Jason Wessel)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1836 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
1 changed file
with
4 additions
and
2 deletions
gdbstub.c
| @@ -654,9 +654,11 @@ static void gdb_vm_stopped(void *opaque, int reason) | @@ -654,9 +654,11 @@ static void gdb_vm_stopped(void *opaque, int reason) | ||
| 654 | if (reason == EXCP_DEBUG) { | 654 | if (reason == EXCP_DEBUG) { |
| 655 | tb_flush(s->env); | 655 | tb_flush(s->env); |
| 656 | ret = SIGTRAP; | 656 | ret = SIGTRAP; |
| 657 | - } | ||
| 658 | - else | 657 | + } else if (reason == EXCP_INTERRUPT) { |
| 658 | + ret = SIGINT; | ||
| 659 | + } else { | ||
| 659 | ret = 0; | 660 | ret = 0; |
| 661 | + } | ||
| 660 | snprintf(buf, sizeof(buf), "S%02x", ret); | 662 | snprintf(buf, sizeof(buf), "S%02x", ret); |
| 661 | put_packet(s, buf); | 663 | put_packet(s, buf); |
| 662 | } | 664 | } |