aboutsummaryrefslogtreecommitdiff
path: root/chardev/char.c
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2018-10-17 10:26:31 +0200
committerMarkus Armbruster <armbru@redhat.com>2018-10-19 14:51:34 +0200
commitb1b769b0f3fd672886ade16da07b540acafeb1cc (patch)
tree17bdfb26a5e9f5cdd60c7d7c481f235c69bb02c6 /chardev/char.c
parentc3b8e3e0ed40112367369683da1e3745cf203ac0 (diff)
char: Use error_printf() to print help and such
Calling error_report() in a function that takes an Error ** argument is suspicious. Convert a few that are actually help and such to error_printf(). Improves output of -chardev help from qemu-system-x86_64: -chardev help: Available chardev backend types: serial ... to Available chardev backend types: serial ... Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: "Marc-André Lureau" <marcandre.lureau@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20181017082702.5581-8-armbru@redhat.com>
Diffstat (limited to 'chardev/char.c')
-rw-r--r--chardev/char.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/chardev/char.c b/chardev/char.c
index e115166995..7f07a1bfbd 100644
--- a/chardev/char.c
+++ b/chardev/char.c
@@ -634,7 +634,7 @@ Chardev *qemu_chr_new_from_opts(QemuOpts *opts, Error **errp)
chardev_name_foreach(help_string_append, str);
- error_report("Available chardev backend types: %s", str->str);
+ error_printf("Available chardev backend types: %s\n", str->str);
g_string_free(str, true);
return NULL;
}