[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 08/14] blkdebug: Use error_setg_file_open() for a better error message
- To: qemu-devel@xxxxxxxxxx
- From: Markus Armbruster <armbru@xxxxxxxxxx>
- Date: Thu, 20 Nov 2025 20:13:33 +0100
- Cc: arei.gonglei@xxxxxxxxxx, pizhenwei@xxxxxxxxxxxxx, alistair.francis@xxxxxxx, stefanb@xxxxxxxxxxxxxxxxxx, kwolf@xxxxxxxxxx, hreitz@xxxxxxxxxx, sw@xxxxxxxxxxx, qemu_oss@xxxxxxxxxxxxx, groug@xxxxxxxx, mst@xxxxxxxxxx, imammedo@xxxxxxxxxx, anisinha@xxxxxxxxxx, kraxel@xxxxxxxxxx, shentey@xxxxxxxxx, npiggin@xxxxxxxxx, harshpb@xxxxxxxxxxxxx, sstabellini@xxxxxxxxxx, anthony@xxxxxxxxxxxxxx, paul@xxxxxxx, edgar.iglesias@xxxxxxxxx, elena.ufimtseva@xxxxxxxxxx, jag.raman@xxxxxxxxxx, sgarzare@xxxxxxxxxx, pbonzini@xxxxxxxxxx, fam@xxxxxxxxxx, philmd@xxxxxxxxxx, alex@xxxxxxxxxxx, clg@xxxxxxxxxx, peterx@xxxxxxxxxx, farosas@xxxxxxx, lizhijian@xxxxxxxxxxx, dave@xxxxxxxxxxx, jasowang@xxxxxxxxxx, samuel.thibault@xxxxxxxxxxxx, michael.roth@xxxxxxx, kkostiuk@xxxxxxxxxx, zhao1.liu@xxxxxxxxx, mtosatti@xxxxxxxxxx, rathc@xxxxxxxxxxxxx, palmer@xxxxxxxxxxx, liwei1518@xxxxxxxxx, dbarboza@xxxxxxxxxxxxxxxx, zhiwei_liu@xxxxxxxxxxxxxxxxx, marcandre.lureau@xxxxxxxxxx, qemu-block@xxxxxxxxxx, qemu-ppc@xxxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxxx, kvm@xxxxxxxxxxxxxxx, qemu-riscv@xxxxxxxxxx
- Delivery-date: Thu, 20 Nov 2025 19:14:01 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
The error message changes from
Could not read blkdebug config file: REASON
to
Could not open 'FNAME': REASON
I think the exact file name is more useful to know than the file's
purpose.
Signed-off-by: Markus Armbruster <armbru@xxxxxxxxxx>
---
block/blkdebug.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/block/blkdebug.c b/block/blkdebug.c
index c54aee0c84..8a4a8cb85e 100644
--- a/block/blkdebug.c
+++ b/block/blkdebug.c
@@ -288,7 +288,7 @@ static int read_config(BDRVBlkdebugState *s, const char
*filename,
if (filename) {
f = fopen(filename, "r");
if (f == NULL) {
- error_setg_errno(errp, errno, "Could not read blkdebug config
file");
+ error_setg_file_open(errp, errno, filename);
return -errno;
}
--
2.49.0
|