[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 06/13] error: remove error_printf_unless_qmp()
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-devel] [PATCH 06/13] error: remove error_printf_unless_qmp() |
Date: |
Fri, 18 Oct 2013 13:29:35 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) |
Wenchao Xia <address@hidden> writes:
> monitor_vprintf() is called in the code path, and it will not print
> when monitor is in qmp mode, so checking monitor mode in
> error_printf_unless_qmp() is useless, remove it to simplify the code.
Suggest to reword:
error_printf_unless_qmp() is no longer useful, because plain
error_printf() doesn't print anything in a QMP monitor since commit
b8b0826.
> Signed-off-by: Wenchao Xia <address@hidden>
> ---
> hw/usb/bus.c | 2 +-
> hw/usb/hcd-ehci.c | 4 ++--
> include/qemu/error-report.h | 1 -
> util/qemu-error.c | 11 -----------
> 4 files changed, 3 insertions(+), 15 deletions(-)
>
> diff --git a/hw/usb/bus.c b/hw/usb/bus.c
> index 72d5b92..817a69a 100644
> --- a/hw/usb/bus.c
> +++ b/hw/usb/bus.c
> @@ -328,7 +328,7 @@ int usb_register_companion(const char *masterbus, USBPort
> *ports[],
> qerror_report(QERR_INVALID_PARAMETER_VALUE, "masterbus",
> "an USB masterbus");
> if (bus) {
> - error_printf_unless_qmp(
> + error_report(
> "USB bus '%s' does not allow companion controllers\n",
> masterbus);
> }
Doesn't this change add location information? I think you want
error_printf(), not error_report(). Same for the other uses.
[...]
- [Qemu-devel] [PATCH 00/13] trivial patches for event, error and monitor, Wenchao Xia, 2013/10/18
- [Qemu-devel] [PATCH 02/13] block: do not include monitor.h in block.c, Wenchao Xia, 2013/10/18
- [Qemu-devel] [PATCH 01/13] block: use type MonitorEvent directly, Wenchao Xia, 2013/10/18
- [Qemu-devel] [PATCH 06/13] error: remove error_printf_unless_qmp(), Wenchao Xia, 2013/10/18
- [Qemu-devel] [PATCH 07/13] error: make error_print_loc() static, Wenchao Xia, 2013/10/18
- [Qemu-devel] [PATCH 05/13] error: define struct Error in only one place, Wenchao Xia, 2013/10/18
- [Qemu-devel] [PATCH 04/13] qapi: rename MonitorEvent to QEvent, Wenchao Xia, 2013/10/18
- [Qemu-devel] [PATCH 03/13] qapi: move MonitorEvent define, Wenchao Xia, 2013/10/18