summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2013-03-25 23:20:36 +0100
committerPetr Mladek <pmladek@suse.cz>2013-03-28 11:40:56 +0000
commitcf57e77ccc1776b8692cd458014036c671fe1078 (patch)
tree1fc0ab892e65ddd81fd4bf90ed1def5d596b8ed8 /sw/source
parent3b68171cedb45ce3d9065e221d4907c682ce08e8 (diff)
coverity#704345 Logically dead code
Change-Id: I72360ada3abedc75b2718742e8a038eb6d214f0c Reviewed-on: https://gerrit.libreoffice.org/3047 Reviewed-by: Petr Mladek <pmladek@suse.cz> Tested-by: Petr Mladek <pmladek@suse.cz>
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/core/crsr/crsrsh.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/sw/source/core/crsr/crsrsh.cxx b/sw/source/core/crsr/crsrsh.cxx
index 73c01bea0f00..581feeb8b895 100644
--- a/sw/source/core/crsr/crsrsh.cxx
+++ b/sw/source/core/crsr/crsrsh.cxx
@@ -925,7 +925,8 @@ int SwCrsrShell::CompareCursor( CrsrCompareType eType ) const
int nRet = 0;
const SwPosition *pFirst = 0, *pSecond = 0;
const SwPaM *pCur = GetCrsr(), *pStk = pCrsrStk;
- if( CurrPtCurrMk != eType && pStk )
+ // cursor on stack is needed if we compare against stack
+ if( pStk || ( eType == CurrPtCurrMk ) )
{
switch ( eType)
{