aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2019-06-03 22:22:36 +0200
committerMax Reitz <mreitz@redhat.com>2019-06-14 14:16:57 +0200
commita2bb6f8c920066fba7bd3fdddf214ea40c0fafab (patch)
tree9295123e947a495d5b58802d148a73f1d1cc979f
parent681b86ac506bf994a92f17e5a8dedb278aab6ede (diff)
downloadqemu-a2bb6f8c920066fba7bd3fdddf214ea40c0fafab.zip
qemu-a2bb6f8c920066fba7bd3fdddf214ea40c0fafab.tar.gz
qemu-a2bb6f8c920066fba7bd3fdddf214ea40c0fafab.tar.bz2
blockdev: Overlays are not snapshots
There are error messages which refer to an overlay node as the snapshot. That is wrong, those are two different things. Signed-off-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Message-id: 20190603202236.1342-3-mreitz@redhat.com Reviewed-by: John Snow <jsnow@redhat.com> Reviewed-by: Alberto Garcia <berto@igalia.com> Signed-off-by: Max Reitz <mreitz@redhat.com>
-rw-r--r--blockdev.c10
-rw-r--r--tests/qemu-iotests/085.out10
2 files changed, 10 insertions, 10 deletions
diff --git a/blockdev.c b/blockdev.c
index fdafa17..b5c0fd3 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -1608,13 +1608,13 @@ static void external_snapshot_prepare(BlkActionState *common,
s->has_snapshot_node_name ? s->snapshot_node_name : NULL;
if (node_name && !snapshot_node_name) {
- error_setg(errp, "New snapshot node name missing");
+ error_setg(errp, "New overlay node name missing");
goto out;
}
if (snapshot_node_name &&
bdrv_lookup_bs(snapshot_node_name, snapshot_node_name, NULL)) {
- error_setg(errp, "New snapshot node name already in use");
+ error_setg(errp, "New overlay node name already in use");
goto out;
}
@@ -1656,7 +1656,7 @@ static void external_snapshot_prepare(BlkActionState *common,
}
if (bdrv_has_blk(state->new_bs)) {
- error_setg(errp, "The snapshot is already in use");
+ error_setg(errp, "The overlay is already in use");
goto out;
}
@@ -1666,12 +1666,12 @@ static void external_snapshot_prepare(BlkActionState *common,
}
if (state->new_bs->backing != NULL) {
- error_setg(errp, "The snapshot already has a backing image");
+ error_setg(errp, "The overlay already has a backing image");
goto out;
}
if (!state->new_bs->drv->supports_backing) {
- error_setg(errp, "The snapshot does not support backing images");
+ error_setg(errp, "The overlay does not support backing images");
goto out;
}
diff --git a/tests/qemu-iotests/085.out b/tests/qemu-iotests/085.out
index 6edf107..2a5f256 100644
--- a/tests/qemu-iotests/085.out
+++ b/tests/qemu-iotests/085.out
@@ -64,13 +64,13 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728 backing_file=TEST_DIR/
=== Invalid command - cannot create a snapshot using a file BDS ===
-{"error": {"class": "GenericError", "desc": "The snapshot does not support backing images"}}
+{"error": {"class": "GenericError", "desc": "The overlay does not support backing images"}}
=== Invalid command - snapshot node used as active layer ===
-{"error": {"class": "GenericError", "desc": "The snapshot is already in use"}}
-{"error": {"class": "GenericError", "desc": "The snapshot is already in use"}}
-{"error": {"class": "GenericError", "desc": "The snapshot is already in use"}}
+{"error": {"class": "GenericError", "desc": "The overlay is already in use"}}
+{"error": {"class": "GenericError", "desc": "The overlay is already in use"}}
+{"error": {"class": "GenericError", "desc": "The overlay is already in use"}}
=== Invalid command - snapshot node used as backing hd ===
@@ -81,7 +81,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728 backing_file=TEST_DIR/
Formatting 'TEST_DIR/t.IMGFMT.base', fmt=IMGFMT size=134217728
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728 backing_file=TEST_DIR/t.IMGFMT.base
{"return": {}}
-{"error": {"class": "GenericError", "desc": "The snapshot already has a backing image"}}
+{"error": {"class": "GenericError", "desc": "The overlay already has a backing image"}}
=== Invalid command - The node does not exist ===