diff options
author | albert-github <albert.tests@gmail.com> | 2019-02-25 09:21:41 (GMT) |
---|---|---|
committer | albert-github <albert.tests@gmail.com> | 2019-02-25 09:21:41 (GMT) |
commit | be1cceffdb3d8487f10fe7a354d360c52979edd3 (patch) | |
tree | 6d2d86b4bd1bc2e1778a929ee2565277e8762520 /src | |
parent | 7c8994e18b57586f116ee223da9bac35b4262570 (diff) | |
download | Doxygen-be1cceffdb3d8487f10fe7a354d360c52979edd3.zip Doxygen-be1cceffdb3d8487f10fe7a354d360c52979edd3.tar.gz Doxygen-be1cceffdb3d8487f10fe7a354d360c52979edd3.tar.bz2 |
Bug 645910 - Segfault on recursion while parsing "\subpage A" in "\page A"
In version 1.7.3 (till 1.8.7) the problem of direct recursion (i.e. in a page is a subpage to itself) we got a segmentation fault, as of 1.8.8 the problem went into an endless loop.
The direct recursion is now detected.
Diffstat (limited to 'src')
-rw-r--r-- | src/doxygen.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/doxygen.cpp b/src/doxygen.cpp index caa13a6..47b16eb 100644 --- a/src/doxygen.cpp +++ b/src/doxygen.cpp @@ -8727,7 +8727,14 @@ static void computePageRelations(Entry *root) for (bii.toFirst();(bi=bii.current());++bii) { PageDef *subPd = Doxygen::pageSDict->find(bi->name); - if (subPd) + if (pd==subPd) + { + err("page defined at line %d of file %s with label %s is a direct " + "subpage of itself! Please remove this cyclic dependency.\n", + pd->docLine(),pd->docFile().data(),pd->name().data()); + exit(1); + } + else if (subPd) { pd->addInnerCompound(subPd); //printf("*** Added subpage relation: %s->%s\n", |