summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorXisco Fauli <xiscofauli@libreoffice.org>2018-10-21 22:47:24 +0200
committerCaolán McNamara <caolanm@redhat.com>2018-10-22 10:00:27 +0200
commitb9e4f8e1d7464858f15030ee55aa2b4a8b86e427 (patch)
treefc26be7e68620e1725bf14d8c42df0e0c9f0e1a8 /sw
parentfbfb65f140f0dea1c782d1d4c97f272d40135426 (diff)
tdf#120703 (PVS): Recurring check.
V571 The 'pColumn->GetWidthOption()' condition was already verified in line 1033. Change-Id: I5bc11bceddc8090f41bf86b45f880ceea3dfb204 Reviewed-on: https://gerrit.libreoffice.org/62158 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/doc/htmltbl.cxx13
1 files changed, 5 insertions, 8 deletions
diff --git a/sw/source/core/doc/htmltbl.cxx b/sw/source/core/doc/htmltbl.cxx
index da0135abd966..346c67c552fe 100644
--- a/sw/source/core/doc/htmltbl.cxx
+++ b/sw/source/core/doc/htmltbl.cxx
@@ -1032,14 +1032,11 @@ void SwHTMLTableLayout::AutoLayoutPass1()
SwHTMLTableLayoutColumn *pColumn = GetColumn( i );
if (pColumn->IsRelWidthOption() && pColumn->GetWidthOption() && nQuotMax)
{
- if( pColumn->GetWidthOption() )
- {
- pColumn->SetMax( pColumn->GetMax() / nQuotMax );
- OSL_ENSURE( pColumn->GetMax() >= pColumn->GetMin(),
- "Minimum width is one column bigger than maximum" );
- if( pColumn->GetMax() < pColumn->GetMin() )
- pColumn->SetMax( pColumn->GetMin() );
- }
+ pColumn->SetMax( pColumn->GetMax() / nQuotMax );
+ OSL_ENSURE( pColumn->GetMax() >= pColumn->GetMin(),
+ "Minimum width is one column bigger than maximum" );
+ if( pColumn->GetMax() < pColumn->GetMin() )
+ pColumn->SetMax( pColumn->GetMin() );
}
m_nMax += pColumn->GetMax();
}