diff options
Diffstat (limited to 'sw/source/core/edit/edlingu.cxx')
-rw-r--r-- | sw/source/core/edit/edlingu.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/core/edit/edlingu.cxx b/sw/source/core/edit/edlingu.cxx index 94186299947a..d62d1cc118a3 100644 --- a/sw/source/core/edit/edlingu.cxx +++ b/sw/source/core/edit/edlingu.cxx @@ -897,7 +897,7 @@ uno::Reference< XSpellAlternatives > // modify the selection accordingly. const sal_Unicode* pChar = aText.getStr(); sal_Int32 nLeft = 0; - while (pChar && *pChar++ == CH_TXTATR_INWORD) + while (*pChar++ == CH_TXTATR_INWORD) ++nLeft; pChar = aText.getLength() ? aText.getStr() + aText.getLength() - 1 : nullptr; sal_Int32 nRight = 0; @@ -1022,7 +1022,7 @@ bool SwEditShell::GetGrammarCorrection( // order to modify the selection accordingly. const sal_Unicode* pChar = aText.getStr(); sal_Int32 nLeft = 0; - while (pChar && *pChar++ == CH_TXTATR_INWORD) + while (*pChar++ == CH_TXTATR_INWORD) ++nLeft; pChar = aText.getLength() ? aText.getStr() + aText.getLength() - 1 : nullptr; sal_Int32 nRight = 0; |