[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v5 16/22] blkdebug: Make filename optional
From: |
Max Reitz |
Subject: |
[Qemu-devel] [PATCH v5 16/22] blkdebug: Make filename optional |
Date: |
Fri, 13 Dec 2013 18:10:27 +0100 |
There is no problem in giving no filename; in this case, it has to be
specified through the "image" option.
Signed-off-by: Max Reitz <address@hidden>
---
block/blkdebug.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/block/blkdebug.c b/block/blkdebug.c
index 0c800ae..fdfc6b0 100644
--- a/block/blkdebug.c
+++ b/block/blkdebug.c
@@ -327,8 +327,10 @@ static void blkdebug_parse_filename(const char *filename,
QDict *options,
/* Parse the blkdebug: prefix */
if (!strstart(filename, "blkdebug:", &filename)) {
/* There was no prefix; therefore, all options have to be already
- present in the QDict (except for the filename) */
- qdict_put(options, "x-image", qstring_from_str(filename));
+ present in the QDict; if a filename is given, pass it */
+ if (filename) {
+ qdict_put(options, "x-image", qstring_from_str(filename));
+ }
return;
}
--
1.8.5.1
- Re: [Qemu-devel] [PATCH v5 12/22] block: Allow recursive "file"s, (continued)
- [Qemu-devel] [PATCH v5 16/22] blkdebug: Make filename optional,
Max Reitz <=
[Qemu-devel] [PATCH v5 18/22] blkverify: Don't require protocol filename, Max Reitz, 2013/12/13
[Qemu-devel] [PATCH v5 17/22] blkverify: Allow command-line configuration, Max Reitz, 2013/12/13
[Qemu-devel] [PATCH v5 19/22] blkdebug: Alias "errno" as "error", Max Reitz, 2013/12/13