diff --git a/monitor.c b/monitor.c index 8bb8bbfd15..83c4edfce0 100644 --- a/monitor.c +++ b/monitor.c @@ -1025,7 +1025,7 @@ int monitor_set_cpu(int cpu_index) CPUState *mon_get_cpu(void) { if (!cur_mon->mon_cpu) { - monitor_set_cpu(0); + monitor_set_cpu(first_cpu->cpu_index); } cpu_synchronize_state(cur_mon->mon_cpu); return cur_mon->mon_cpu;