The data is degenerate, but since the landxml schema document specifically notes that cyclic pntRefs are valid, blowing the stack is probably not appropriate behaviour.
specifics:
xml snippet:
<CgPoint ... name="a" pntRef="b"/>
<CgPoint ... name="b" pntRef="a"/>
suppose the
CgPoint* m = otherCgPoint->resolveCoor()
This blows the stack, since resolveCoor(), if the object in question doesn't have coordinates of its own, but does have a pntRef, will recursively call resolveCoor on the refered point name. Since this is cyclic, it will blow the stack.
Proposed solutions:
(1) minimized developer time: provide an integer argument to resolveCoor( int maxDepth=100 ), and don't recurse more than that (throw exception). This way those who care about stack size can limit/expand the max depth, and those that don't can use the default. Don't be concerned with the performance in such pathological cases.
(2) maximize correctness: Use any of the solutions to the google problem "finding a cycle in a linked list".