aboutsummaryrefslogtreecommitdiff
path: root/block/bochs.c
diff options
context:
space:
mode:
Diffstat (limited to 'block/bochs.c')
-rw-r--r--block/bochs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/block/bochs.c b/block/bochs.c
index 51d9a90577..4d6403f904 100644
--- a/block/bochs.c
+++ b/block/bochs.c
@@ -129,7 +129,8 @@ static int bochs_open(BlockDriverState *bs, QDict *options, int flags,
strcmp(bochs.subtype, GROWING_TYPE) ||
((le32_to_cpu(bochs.version) != HEADER_VERSION) &&
(le32_to_cpu(bochs.version) != HEADER_V1))) {
- return -EMEDIUMTYPE;
+ error_setg(errp, "Image not in Bochs format");
+ return -EINVAL;
}
if (le32_to_cpu(bochs.version) == HEADER_V1) {