snapshot: Avoid infloop during REDEFINE

Commit 55c2ab3e accidentally introduced an infinite loop while
checking whether a redefined snapshot would cause an infinite loop in
chasing its parents back to a root.  Alas, 'make check' did not catch
it, so my next patch will be a testsuite improvement that would have
hung and prevented the bug from being checked in to begin with.

Signed-off-by: Eric Blake <eblake@redhat.com>
Acked-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Eric Blake 2019-03-23 17:04:43 -05:00
parent f1d6585300
commit 9884b2d185

View File

@ -962,6 +962,7 @@ virDomainSnapshotRedefinePrep(virDomainPtr domain,
vm->def->name);
break;
}
otherdef = virDomainSnapshotObjGetDef(other);
}
}