Kaydet (Commit) bbc17bc8 authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#704347 Logically dead code

const bool bSelectUp = ( bVert && !bRow );
...
if ( bSelectUp )
    ...
else
    bVert ? (bRow ? 0 : 3) : (bRow ? 2 : 1)

the bRow is only queried on the non-bSelectUp path
if bVert is true then bRow must be also true, because
if bVert is true and bRow is false we would be in
the other branch

Change-Id: I784b41dbfda1afaf574fd8259eff3ab5cc5550fe
üst 1d687e81
...@@ -218,9 +218,9 @@ bool SwCrsrShell::_SelTblRowOrCol( bool bRow, bool bRowSimple ) ...@@ -218,9 +218,9 @@ bool SwCrsrShell::_SelTblRowOrCol( bool bRow, bool bRowSimple )
else else
{ {
// will become point of table cursor // will become point of table cursor
pStt = aCells[ bVert ? (bRow ? 0 : 3) : (bRow ? 2 : 1) ]->GetTabBox(); pStt = aCells[bVert ? 0 : (bRow ? 2 : 1)]->GetTabBox();
// will become mark of table cursor // will become mark of table cursor
pEnd = aCells[ bVert ? (bRow ? 3 : 0) : (bRow ? 1 : 2) ]->GetTabBox(); pEnd = aCells[bVert ? 3 : (bRow ? 1 : 2)]->GetTabBox();
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment