From b2c827e516c82a1efe58602e10f114c104dd7476 Mon Sep 17 00:00:00 2001 From: Marc Jeanmougin Date: Thu, 15 Oct 2015 01:12:02 +0200 Subject: Detect trivial loops Fixed bugs: - https://launchpad.net/bugs/1328079 (bzr r14412) --- src/uri-references.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/uri-references.cpp') diff --git a/src/uri-references.cpp b/src/uri-references.cpp index 04f904d39..0aae9b39d 100644 --- a/src/uri-references.cpp +++ b/src/uri-references.cpp @@ -75,6 +75,7 @@ bool URIReference::_acceptObject(SPObject *obj) const { for(int i=positions.size()-2;i>=0;i--)owner=owner->childList(false)[positions[i]]; } //once we have the "original" object (hopefully) we look at who is referencing it + if(obj == owner)return false; std::list todo(owner->hrefList); todo.push_front(owner->parent); while(!todo.empty()){ -- cgit v1.2.3