From 4a44d85e28bd282f53ccf0fa933dd71b8744a229 Mon Sep 17 00:00:00 2001 From: Seiji Aguchi Date: Mon, 5 Aug 2013 15:40:44 -0400 Subject: Convert stderr message calling error_get_pretty() to error_report() Convert stderr messages calling error_get_pretty() to error_report(). Timestamp is prepended by -msg timstamp option with it. Per Markus's comment below, A conversion from fprintf() to error_report() is always an improvement, regardless of error_get_pretty(). http://marc.info/?l=qemu-devel&m=137513283408601&w=2 But, it is not reasonable to convert them at one time because fprintf() is used everwhere in qemu. So, it should be done step by step with avoiding regression. Signed-off-by: Seiji Aguchi Reviewed-by: Laszlo Ersek Signed-off-by: Luiz Capitulino --- qemu-char.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'qemu-char.c') diff --git a/qemu-char.c b/qemu-char.c index 1be1cf6..5446b88 100644 --- a/qemu-char.c +++ b/qemu-char.c @@ -3344,7 +3344,7 @@ CharDriverState *qemu_chr_new(const char *label, const char *filename, void (*in chr = qemu_chr_new_from_opts(opts, init, &err); if (error_is_set(&err)) { - fprintf(stderr, "%s\n", error_get_pretty(err)); + error_report("%s", error_get_pretty(err)); error_free(err); } if (chr && qemu_opt_get_bool(opts, "mux", 0)) { -- cgit v1.1