From patchwork Thu Feb 14 10:47:12 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Laurent Vivier X-Patchwork-Id: 10812421 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 88B4813A4 for ; Thu, 14 Feb 2019 10:48:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 76EA42D6AD for ; Thu, 14 Feb 2019 10:48:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6A06E2D6B0; Thu, 14 Feb 2019 10:48:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 128C42D6AD for ; Thu, 14 Feb 2019 10:48:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2395426AbfBNKsE (ORCPT ); Thu, 14 Feb 2019 05:48:04 -0500 Received: from mout.kundenserver.de ([212.227.126.130]:38165 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2395336AbfBNKsC (ORCPT ); Thu, 14 Feb 2019 05:48:02 -0500 Received: from localhost.localdomain ([78.238.229.36]) by mrelayeu.kundenserver.de (mreue010 [212.227.15.167]) with ESMTPSA (Nemesis) id 1MQ67s-1ggyzQ0KCO-00M1Dy; Thu, 14 Feb 2019 11:47:44 +0100 From: Laurent Vivier To: qemu-devel@nongnu.org Cc: Laurent Vivier , Paolo Bonzini , kvm@vger.kernel.org, libvir-list@redhat.com, "Michael S. Tsirkin" , Eric Blake , Markus Armbruster , Michael Tokarev , "Dr. David Alan Gilbert" , qemu-trivial@nongnu.org, Gerd Hoffmann , Artyom Tarasenko , Kamil Rytarowski , Mark Cave-Ayland , =?utf-8?q?Philippe_Mathie?= =?utf-8?q?u-Daud=C3=A9?= Subject: [PULL 09/14] HMP: Prepend errors with 'Error:' Date: Thu, 14 Feb 2019 11:47:12 +0100 Message-Id: <20190214104717.3543-10-laurent@vivier.eu> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190214104717.3543-1-laurent@vivier.eu> References: <20190214104717.3543-1-laurent@vivier.eu> MIME-Version: 1.0 X-Provags-ID: V03:K1:oGbypwVScPHHEzj9ZvWC6uTpZ9QmKHA9ZweDcvFgFw4KlmgeF8J GfyBD//AVbHoQWFRz3qgJQZDYxqzpURK0p6SshkWcLpjcIZHqgZrE3FFOKLrzFqgEXo1z9N iBljts6IW9ZspTZA2yy23QX+NajCsJ1clua3S9BU+t89D/7og3oCA9zO+cBAWf8daDfgdZG QMNSNnOBEQ/re1PzApEVw== X-UI-Out-Filterresults: notjunk:1;V03:K0:dtU9daHTNIw=:GnukZdjyBffmVVs7hKGk4M CAco6FUK5YZH1oIr46EhswAghQ5H+YKJYg9zo5n7JTClJ6NwiBX7fvxOjfWdxT4U4GFhKZ+b6 GeDRWaPQ36yJOnw9pILnnhMYwMZDSN9reCV0Gir5BsBng6hPNIGjHU9OkgZTlmZd/cgJzrM9d n8bWMCbfs9DBrV8TtTkI3rlUqYbGHIjAO+JlyjVmgFXBjM10Ixogw4HHGaVIKa/Y75a7GxBpd LTeVDp3ubc8yvy84gThS/FbZTrubgOcfnfJfwL08RG7XUIksp88mnJ/M1DcLcN4F0y3u34w69 xJ8uUKnF1+fLsDZTnkqL+7W0MzPYR63gcClMzEfsn+8sdre02Vs3Onc1cwHAj2R6vGYQxxJeL +WJ0VEIw2NjXVjB/1LY3tFLW7aVlJ8T4UuhzrOhXhrwWn9WjyXJupeOyjJMjjlOE1AMk/5EWh 67dqBM0ZKSh63R3yjWCsGfr6OTWOCYJzr2uaMxgAZriq89sz0nP0J4FG2kaNy68FC6hX9P5sL Ew0RoIbiGYSXXzrdHHpdrTqwCWYoqTOc73R61daSYih2f/WZh+gtrcI0qiipeW6gJ5ty+3XDm 74cCl6hLgiFKPXeHgFshleFR2jHTAZb0avIkuWzRSvuSlNDJ95EwIz40rfG2MNmeRfxTleRDn K86kUpA7RVrt0DS/bWZqAa2ERITToUW2ypO7/2a12oS6nIR6hceN0E9AyNtx2qOahthZ5th74 6jDKX5OwSaapcgdG0gbcOkT4j1nh1AdzYeBaZNMN0ylURpFqeLJuX2QcU+c= Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: "Dr. David Alan Gilbert" Always make error messages start with 'Error:' as a fallback to make sure that anything parsing them can tell it failed. Note: Some places don't use hmp_handle_error Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Michael S. Tsirkin Message-Id: <20190212134758.10514-3-dgilbert@redhat.com> Signed-off-by: Laurent Vivier --- hmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hmp.c b/hmp.c index b2a2b1f84e33..4d14718fea4a 100644 --- a/hmp.c +++ b/hmp.c @@ -62,7 +62,7 @@ static void hmp_handle_error(Monitor *mon, Error **errp) { assert(errp); if (*errp) { - error_report_err(*errp); + error_reportf_err(*errp, "Error: "); } }