diff options
-rw-r--r-- | dw/textblock.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dw/textblock.cc b/dw/textblock.cc index e5561f6a..2cf4d597 100644 --- a/dw/textblock.cc +++ b/dw/textblock.cc @@ -1695,7 +1695,7 @@ int Textblock::findParagraphOfWord (int wordIndex) if (wordIndex < 0 || wordIndex >= words->size () || // It may be that the paragraphs list is incomplete. But look // also at fillParagraphs, where this method is called. - (paragraphs->size () > 0 && + (paragraphs->size () == 0 || wordIndex > paragraphs->getLastRef()->lastWord)) return -1; |