aboutsummaryrefslogtreecommitdiff
path: root/qemu-img.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2010-12-16 15:10:32 +0100
committerKevin Wolf <kwolf@redhat.com>2010-12-17 16:11:03 +0100
commit53f76e5857b66dd7fa90efa9ea8326eff5aa693f (patch)
tree416a0dc91256ac8984e6133199985a51bb1cbb7a /qemu-img.c
parent1bdaa28d7a521628345a46626c2fd6c279562776 (diff)
downloadqemu-53f76e5857b66dd7fa90efa9ea8326eff5aa693f.zip
qemu-53f76e5857b66dd7fa90efa9ea8326eff5aa693f.tar.gz
qemu-53f76e5857b66dd7fa90efa9ea8326eff5aa693f.tar.bz2
qemu-img: Call error_set_progname
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 <kwolf@redhat.com>
Diffstat (limited to 'qemu-img.c')
-rw-r--r--qemu-img.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/qemu-img.c b/qemu-img.c
index 1d936ed..f576cfb 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"
@@ -1612,6 +1613,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();