From: Fam Zheng <famz@redhat.com>
To: qemu-devel@nongnu.org
Cc: Markus Armbruster <armbru@redhat.com>,
Kevin Wolf <kwolf@redhat.com>, Max Reitz <mreitz@redhat.com>,
qemu-block@nongnu.org
Subject: [Qemu-devel] [PATCH 1/2] qapi: Tweak error message of bdrv_query_image_info
Date: Thu, 19 Jan 2017 21:07:58 +0800 [thread overview]
Message-ID: <20170119130759.28319-2-famz@redhat.com> (raw)
In-Reply-To: <20170119130759.28319-1-famz@redhat.com>
@bs doesn't always have a device name, such as when it comes from
"qemu-img info". Report file name instead.
Signed-off-by: Fam Zheng <famz@redhat.com>
---
block/qapi.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/block/qapi.c b/block/qapi.c
index a62e862..6329735 100644
--- a/block/qapi.c
+++ b/block/qapi.c
@@ -237,8 +237,8 @@ void bdrv_query_image_info(BlockDriverState *bs,
size = bdrv_getlength(bs);
if (size < 0) {
- error_setg_errno(errp, -size, "Can't get size of device '%s'",
- bdrv_get_device_name(bs));
+ error_setg_errno(errp, -size, "Can't get image size '%s'",
+ bs->exact_filename);
goto out;
}
--
2.9.3
next prev parent reply other threads:[~2017-01-19 13:08 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-19 13:07 [Qemu-devel] [PATCH 0/2] block: Fix iotests 059 Fam Zheng
2017-01-19 13:07 ` Fam Zheng [this message]
2017-01-21 19:33 ` [Qemu-devel] [PATCH 1/2] qapi: Tweak error message of bdrv_query_image_info Max Reitz
2017-01-19 13:07 ` [Qemu-devel] [PATCH 2/2] iotests: Fix reference output for 059 Fam Zheng
2017-01-19 14:30 ` [Qemu-devel] [PATCH 0/2] block: Fix iotests 059 Eric Blake
2017-01-21 19:35 ` Max Reitz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170119130759.28319-2-famz@redhat.com \
--to=famz@redhat.com \
--cc=armbru@redhat.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).