From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=42762 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PTEZO-0006pd-BW for qemu-devel@nongnu.org; Thu, 16 Dec 2010 09:12:35 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PTEZN-0008Ax-AH for qemu-devel@nongnu.org; Thu, 16 Dec 2010 09:12:34 -0500 Received: from mx1.redhat.com ([209.132.183.28]:54678) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PTEZM-0008Ak-Tu for qemu-devel@nongnu.org; Thu, 16 Dec 2010 09:12:33 -0500 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id oBGECVV4014533 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 16 Dec 2010 09:12:32 -0500 From: Kevin Wolf Date: Thu, 16 Dec 2010 15:13:43 +0100 Message-Id: <1292508823-13015-1-git-send-email-kwolf@redhat.com> Subject: [Qemu-devel] [PATCH] qemu-img: Call error_set_progname List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: kwolf@redhat.com, Jes.Sorensen@redhat.com Call error_set_progname during the qemu-img initialization, so that error messages printed with error_report() use the right prefix. Signed-off-by: Kevin Wolf --- qemu-img.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/qemu-img.c b/qemu-img.c index 603bdb3..0ff179f 100644 --- a/qemu-img.c +++ b/qemu-img.c @@ -23,6 +23,7 @@ */ #include "qemu-common.h" #include "qemu-option.h" +#include "qemu-error.h" #include "osdep.h" #include "sysemu.h" #include "block_int.h" @@ -1508,6 +1509,8 @@ int main(int argc, char **argv) const img_cmd_t *cmd; const char *cmdname; + error_set_progname(argv[0]); + bdrv_init(); if (argc < 2) help(); -- 1.7.2.3