Revision 4fdc94b4
b/monitor.c | ||
---|---|---|
556 | 556 |
} |
557 | 557 |
} |
558 | 558 |
|
559 |
static void do_info(Monitor *mon, const QDict *qdict, QObject **ret_data)
|
|
559 |
static int do_info(Monitor *mon, const QDict *qdict, QObject **ret_data)
|
|
560 | 560 |
{ |
561 | 561 |
const mon_cmd_t *cmd; |
562 | 562 |
const char *item = qdict_get_try_str(qdict, "item"); |
... | ... | |
574 | 574 |
if (cmd->name == NULL) { |
575 | 575 |
if (monitor_ctrl_mode(mon)) { |
576 | 576 |
qemu_error_new(QERR_COMMAND_NOT_FOUND, item); |
577 |
return; |
|
577 |
return -1;
|
|
578 | 578 |
} |
579 | 579 |
goto help; |
580 | 580 |
} |
... | ... | |
606 | 606 |
if (monitor_ctrl_mode(mon)) { |
607 | 607 |
/* handler not converted yet */ |
608 | 608 |
qemu_error_new(QERR_COMMAND_NOT_FOUND, item); |
609 |
return -1; |
|
609 | 610 |
} else { |
610 | 611 |
cmd->mhandler.info(mon); |
611 | 612 |
} |
612 | 613 |
} |
613 | 614 |
|
614 |
return; |
|
615 |
return 0;
|
|
615 | 616 |
|
616 | 617 |
help: |
617 | 618 |
help_cmd(mon, "info"); |
619 |
return 0; |
|
618 | 620 |
} |
619 | 621 |
|
620 | 622 |
static void do_info_version_print(Monitor *mon, const QObject *data) |
b/qemu-monitor.hx | ||
---|---|---|
43 | 43 |
.params = "[subcommand]", |
44 | 44 |
.help = "show various information about the system state", |
45 | 45 |
.user_print = monitor_user_noop, |
46 |
.mhandler.cmd_new = do_info,
|
|
46 |
.cmd_new_ret = do_info,
|
|
47 | 47 |
}, |
48 | 48 |
|
49 | 49 |
STEXI |
Also available in: Unified diff