summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuboš Luňák <l.lunak@collabora.com>2022-04-21 21:03:59 +0200
committerLuboš Luňák <l.lunak@collabora.com>2022-04-21 22:08:35 +0200
commit1768d5705dc72328ae2369fac7fc82437fef4ae1 (patch)
treea6c496e76eeab69c7af24110cd530e4df2c45ecc
parent9ec0395a0666ce07871b945dcb9a741d2237103b (diff)
simply return from a loop
Change-Id: I4e10945f32dfb535663ea7392f19532e45ca9ee3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133301 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
-rw-r--r--sc/source/core/data/table1.cxx7
1 files changed, 3 insertions, 4 deletions
diff --git a/sc/source/core/data/table1.cxx b/sc/source/core/data/table1.cxx
index e82fdf9d4cfd..e864bd23974f 100644
--- a/sc/source/core/data/table1.cxx
+++ b/sc/source/core/data/table1.cxx
@@ -1234,11 +1234,10 @@ bool ScTable::IsEmptyLine( SCROW nRow, SCCOL nStartCol, SCCOL nEndCol ) const
nEndCol = std::min<SCCOL>( nEndCol, aCol.size()-1 );
- bool bFound = false;
- for (SCCOL i=nStartCol; i<=nEndCol && !bFound; i++)
+ for (SCCOL i=nStartCol; i<=nEndCol; i++)
if (aCol[i].HasDataAt(nRow))
- bFound = true;
- return !bFound;
+ return false;
+ return true;
}
void ScTable::LimitChartArea( SCCOL& rStartCol, SCROW& rStartRow, SCCOL& rEndCol, SCROW& rEndRow ) const