diff --git a/blockdev.c b/blockdev.c index 862aa1b9aa..57ee41b73e 100644 --- a/blockdev.c +++ b/blockdev.c @@ -1562,7 +1562,12 @@ static void external_snapshot_prepare(BlkActionState *common, goto out; } - if (state->new_bs->backing != NULL) { + if (state->new_bs->drv->is_filter) { + error_setg(errp, "Filters cannot be used as overlays"); + goto out; + } + + if (bdrv_cow_child(state->new_bs)) { error_setg(errp, "The overlay already has a backing image"); goto out; }