conf: checkpoint: Don't clear current checkpoint when redefining an existing one

There's no point in clearing the current checkpoint when we are just
changing the definition of the current checkpoint as by the virtue of the
'update_current' flag the same checkpoint would become current in
qemuCheckpointCreateXML.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
Peter Krempa 2019-10-01 07:22:14 +02:00
parent 4d60e7fdd4
commit a8f92d2d7f

View File

@ -569,11 +569,6 @@ virDomainCheckpointRedefinePrep(virDomainObjPtr vm,
def->parent.dom, xmlopt))
return -1;
if (other == virDomainCheckpointGetCurrent(vm->checkpoints)) {
*update_current = true;
virDomainCheckpointSetCurrent(vm->checkpoints, NULL);
}
/* Drop and rebuild the parent relationship, but keep all
* child relations by reusing chk. */
virDomainMomentDropParent(other);