Skip to content

Commit

Permalink
migration: Give one error if trying to set COMPRESSION and XBZRLE
Browse files Browse the repository at this point in the history
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231019110724.15324-3-quintela@redhat.com>
  • Loading branch information
Juan Quintela committed Oct 30, 2023
1 parent d869f62 commit 0e19562
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions migration/options.c
Original file line number Diff line number Diff line change
Expand Up @@ -625,6 +625,13 @@ bool migrate_caps_check(bool *old_caps, bool *new_caps, Error **errp)
}
}

if (new_caps[MIGRATION_CAPABILITY_COMPRESS]) {
if (new_caps[MIGRATION_CAPABILITY_XBZRLE]) {
error_setg(errp, "Compression is not compatible with xbzrle");
return false;
}
}

return true;
}

Expand Down

0 comments on commit 0e19562

Please sign in to comment.