diff options
Diffstat (limited to 'sw/source/core/doc/docbm.cxx')
-rw-r--r-- | sw/source/core/doc/docbm.cxx | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sw/source/core/doc/docbm.cxx b/sw/source/core/doc/docbm.cxx index 5dbd88064c73..e047b2d1e319 100644 --- a/sw/source/core/doc/docbm.cxx +++ b/sw/source/core/doc/docbm.cxx @@ -218,6 +218,12 @@ namespace { return nFirstContent < nSecondContent; } + SwContentNode const*const pFirstNode(rFirstStart.nContent.GetContentNode()); + SwContentNode const*const pSecondNode(rSecondStart.nContent.GetContentNode()); + if ((pFirstNode != nullptr) != (pSecondNode != nullptr)) + { // consistency with SwPosition::operator< + return pSecondNode != nullptr; + } auto *const pCRFirst (dynamic_cast<::sw::mark::CrossRefBookmark const*>(pFirst)); auto *const pCRSecond(dynamic_cast<::sw::mark::CrossRefBookmark const*>(pSecond)); if ((pCRFirst == nullptr) == (pCRSecond == nullptr)) |