mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-10-01 20:05:46 +00:00
util: Fix logic in virFileSetCOW
When COW is not explicitly requested to be disabled or enabled, the
function is supposed to do nothing on non-BTRFS file systems.
Fixes commit 7230bc95aa
.
https://bugzilla.redhat.com/show_bug.cgi?id=1866157
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
This commit is contained in:
parent
d293a556d7
commit
2edd63a0db
@ -4522,7 +4522,7 @@ virFileSetCOW(const char *path,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (buf.f_type != BTRFS_SUPER_MAGIC) {
|
if (buf.f_type != BTRFS_SUPER_MAGIC) {
|
||||||
if (state == VIR_TRISTATE_BOOL_ABSENT) {
|
if (state != VIR_TRISTATE_BOOL_ABSENT) {
|
||||||
virReportSystemError(ENOSYS,
|
virReportSystemError(ENOSYS,
|
||||||
_("unable to control COW flag on '%s', not btrfs"),
|
_("unable to control COW flag on '%s', not btrfs"),
|
||||||
path);
|
path);
|
||||||
|
Loading…
Reference in New Issue
Block a user