From patchwork Fri Jan 22 14:38:34 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kurz X-Patchwork-Id: 8090791 Return-Path: X-Original-To: patchwork-qemu-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 96A13BEEE5 for ; Fri, 22 Jan 2016 14:40:25 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 0A85C203F7 for ; Fri, 22 Jan 2016 14:40:25 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 5991C20256 for ; Fri, 22 Jan 2016 14:40:24 +0000 (UTC) Received: from localhost ([::1]:54194 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMcsx-0007z0-QU for patchwork-qemu-devel@patchwork.kernel.org; Fri, 22 Jan 2016 09:40:23 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:34518) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMcrm-0005rx-M3 for qemu-devel@nongnu.org; Fri, 22 Jan 2016 09:39:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aMcrj-0006HU-DU for qemu-devel@nongnu.org; Fri, 22 Jan 2016 09:39:10 -0500 Received: from e06smtp05.uk.ibm.com ([195.75.94.101]:40115) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMcri-0006HL-RD for qemu-devel@nongnu.org; Fri, 22 Jan 2016 09:39:07 -0500 Received: from localhost by e06smtp05.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 22 Jan 2016 14:39:05 -0000 Received: from d06dlp03.portsmouth.uk.ibm.com (9.149.20.15) by e06smtp05.uk.ibm.com (192.168.101.135) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Fri, 22 Jan 2016 14:39:04 -0000 X-IBM-Helo: d06dlp03.portsmouth.uk.ibm.com X-IBM-MailFrom: gkurz@linux.vnet.ibm.com X-IBM-RcptTo: qemu-devel@nongnu.org Received: from b06cxnps4075.portsmouth.uk.ibm.com (d06relay12.portsmouth.uk.ibm.com [9.149.109.197]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id 9E0251B0804B for ; Fri, 22 Jan 2016 14:39:09 +0000 (GMT) Received: from d06av06.portsmouth.uk.ibm.com (d06av06.portsmouth.uk.ibm.com [9.149.37.217]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id u0MEd4CF61931658 for ; Fri, 22 Jan 2016 14:39:04 GMT Received: from d06av06.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av06.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id u0MEd3hB005883 for ; Fri, 22 Jan 2016 09:39:03 -0500 Received: from smtp.lab.toulouse-stg.fr.ibm.com (srv01.lab.toulouse-stg.fr.ibm.com [9.101.4.1]) by d06av06.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id u0MEd3kC005873; Fri, 22 Jan 2016 09:39:03 -0500 Received: from bahia.huguette.org (icon-9-164-177-135.megacenter.de.ibm.com [9.164.177.135]) by smtp.lab.toulouse-stg.fr.ibm.com (Postfix) with ESMTP id B418C220531; Fri, 22 Jan 2016 15:39:02 +0100 (CET) From: Greg Kurz To: qemu-devel@nongnu.org Date: Fri, 22 Jan 2016 15:38:34 +0100 Message-Id: <1453473514-20057-3-git-send-email-gkurz@linux.vnet.ibm.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1453473514-20057-1-git-send-email-gkurz@linux.vnet.ibm.com> References: <1453473514-20057-1-git-send-email-gkurz@linux.vnet.ibm.com> X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 16012214-0021-0000-0000-00000589E14F X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 195.75.94.101 Cc: Peter Maydell , "Aneesh Kumar K.V" , Greg Kurz Subject: [Qemu-devel] [PULL 2/2] fsdev: use error_report() instead of fprintf(stderr) X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Only fix the code that gets built into QEMU. Reviewed-by: Markus Armbruster Signed-off-by: Greg Kurz --- fsdev/qemu-fsdev.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/fsdev/qemu-fsdev.c b/fsdev/qemu-fsdev.c index ccfec139ab2b..55e2f7a0fb58 100644 --- a/fsdev/qemu-fsdev.c +++ b/fsdev/qemu-fsdev.c @@ -17,6 +17,7 @@ #include "qemu/osdep.h" #include "qemu-common.h" #include "qemu/config-file.h" +#include "qemu/error-report.h" static QTAILQ_HEAD(FsDriverEntry_head, FsDriverListEntry) fsdriver_entries = QTAILQ_HEAD_INITIALIZER(fsdriver_entries); @@ -40,7 +41,7 @@ int qemu_fsdev_add(QemuOpts *opts) bool ro = qemu_opt_get_bool(opts, "readonly", 0); if (!fsdev_id) { - fprintf(stderr, "fsdev: No id specified\n"); + error_report("fsdev: No id specified"); return -1; } @@ -52,11 +53,11 @@ int qemu_fsdev_add(QemuOpts *opts) } if (i == ARRAY_SIZE(FsDrivers)) { - fprintf(stderr, "fsdev: fsdriver %s not found\n", fsdriver); + error_report("fsdev: fsdriver %s not found", fsdriver); return -1; } } else { - fprintf(stderr, "fsdev: No fsdriver specified\n"); + error_report("fsdev: No fsdriver specified"); return -1; }