diff --git a/block/qcow2-snapshot.c b/block/qcow2-snapshot.c index 42f971b590930c2fb6a0a432e76a94a903e359ad..4561a2abf91792f0643e1f4b505d4a7eb3316204 100644 --- a/block/qcow2-snapshot.c +++ b/block/qcow2-snapshot.c @@ -331,7 +331,7 @@ int qcow2_snapshot_create(BlockDriverState *bs, QEMUSnapshotInfo *sn_info) /* Check that the ID is unique */ if (find_snapshot_by_id(bs, sn_info->id_str) >= 0) { - return -ENOENT; + return -EEXIST; } /* Populate sn with passed data */