snapshot: Avoid infloop during REDEFINE
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 <a9da18479c871fe903d9590822cfe2629c6a4d11@redhat.com>
Acked-by: Michal Privoznik <83d82aaba2eed257f4814b0c239c260c4caaadf0@redhat.com>

zippy2/libvirt,olafhering/libvirt,eskultety/libvirt,olafhering/libvirt,zippy2/libvirt,zippy2/libvirt,crobinso/libvirt,jardasgit/libvirt,zippy2/libvirt,fabianfreyer/libvirt,fabianfreyer/libvirt,fabianfreyer/libvirt,eskultety/libvirt,nertpinx/libvirt,crobinso/libvirt,jfehlig/libvirt,jardasgit/libvirt,crobinso/libvirt,crobinso/libvirt,andreabolognani/libvirt,jardasgit/libvirt,libvirt/libvirt,olafhering/libvirt,andreabolognani/libvirt,eskultety/libvirt,jardasgit/libvirt,andreabolognani/libvirt,jfehlig/libvirt,jfehlig/libvirt,jfehlig/libvirt,eskultety/libvirt,nertpinx/libvirt,eskultety/libvirt,libvirt/libvirt,nertpinx/libvirt,libvirt/libvirt,andreabolognani/libvirt,fabianfreyer/libvirt,nertpinx/libvirt,jardasgit/libvirt,libvirt/libvirt,olafhering/libvirt,nertpinx/libvirt,andreabolognani/libvirt,fabianfreyer/libvirt