summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/tools/qdoc/ditaxmlgenerator.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/tools/qdoc/ditaxmlgenerator.cpp b/src/tools/qdoc/ditaxmlgenerator.cpp
index 9bb64d41ef..a9182c2231 100644
--- a/src/tools/qdoc/ditaxmlgenerator.cpp
+++ b/src/tools/qdoc/ditaxmlgenerator.cpp
@@ -2414,7 +2414,7 @@ void DitaXmlGenerator::writeRelatedLinks(const FakeNode* node, CodeMarker* marke
if (node->links().contains(Node::PreviousLink)) {
linkPair = node->links()[Node::PreviousLink];
linkNode = findNodeForTarget(linkPair.first, node, marker);
- if (linkNode->type() == Node::Fake) {
+ if (linkNode && linkNode->type() == Node::Fake) {
const FakeNode *fakeNode = static_cast<const FakeNode*>(linkNode);
linkPair.second = fakeNode->title();
}
@@ -2423,7 +2423,7 @@ void DitaXmlGenerator::writeRelatedLinks(const FakeNode* node, CodeMarker* marke
if (node->links().contains(Node::NextLink)) {
linkPair = node->links()[Node::NextLink];
linkNode = findNodeForTarget(linkPair.first, node, marker);
- if (linkNode->type() == Node::Fake) {
+ if (linkNode && linkNode->type() == Node::Fake) {
const FakeNode *fakeNode = static_cast<const FakeNode*>(linkNode);
linkPair.second = fakeNode->title();
}
@@ -2432,7 +2432,7 @@ void DitaXmlGenerator::writeRelatedLinks(const FakeNode* node, CodeMarker* marke
if (node->links().contains(Node::StartLink)) {
linkPair = node->links()[Node::StartLink];
linkNode = findNodeForTarget(linkPair.first, node, marker);
- if (linkNode->type() == Node::Fake) {
+ if (linkNode && linkNode->type() == Node::Fake) {
const FakeNode *fakeNode = static_cast<const FakeNode*>(linkNode);
linkPair.second = fakeNode->title();
}