diff options
author | Markus Armbruster <armbru@redhat.com> | 2010-05-11 15:36:46 +0200 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2010-06-15 09:41:58 +0200 |
commit | dd5b0d71d660a4e31bdf8bd0d130ce582833db9f (patch) | |
tree | 11bfbcbfeea9ff46aa3ebb7a462456e1d539c0a9 | |
parent | feeee5aca765606818e00f5a19d19f141f4ae365 (diff) |
Fix regression for "-drive file="
Empty file used to create an empty drive (no media). Since commit
9dfd7c7a, it's an error: "qemu: could not open disk image : No such
file or directory". Older versions of libvirt can choke on this.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
-rw-r--r-- | blockdev.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/blockdev.c b/blockdev.c index 642ce756ac..dbeef09ceb 100644 --- a/blockdev.c +++ b/blockdev.c @@ -462,7 +462,7 @@ DriveInfo *drive_init(QemuOpts *opts, int default_to_scsi, int *fatal_error) case IF_COUNT: abort(); } - if (!file) { + if (!file || !*file) { *fatal_error = 0; return NULL; } |