mirror of
https://github.com/qemu/qemu.git
synced 2026-07-08 17:46:10 +00:00
gdbstub: Reduce @type variable scope
Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com> Reviewed-by: Daniel Henrique Barboza <daniel.barboza@oss.qualcomm.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-ID: <20260705215729.62196-24-philmd@oss.qualcomm.com>
This commit is contained in:
@@ -125,7 +125,6 @@ static void gdb_vm_state_change(void *opaque, bool running, RunState state)
|
||||
CPUState *cpu = gdbserver_state.c_cpu;
|
||||
g_autoptr(GString) buf = g_string_new(NULL);
|
||||
g_autoptr(GString) tid = g_string_new(NULL);
|
||||
const char *type;
|
||||
int ret;
|
||||
|
||||
if (running || gdbserver_state.state == RS_INACTIVE) {
|
||||
@@ -151,6 +150,8 @@ static void gdb_vm_state_change(void *opaque, bool running, RunState state)
|
||||
switch (state) {
|
||||
case RUN_STATE_DEBUG:
|
||||
if (cpu->watchpoint_hit) {
|
||||
const char *type;
|
||||
|
||||
switch (cpu->watchpoint_hit->flags & BP_MEM_ACCESS) {
|
||||
case BP_MEM_READ:
|
||||
type = "r";
|
||||
|
||||
Reference in New Issue
Block a user