summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-10-12 08:57:55 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-10-15 12:53:38 +0200
commit6eba86ae9d6c8550e069ef933889610aee309381 (patch)
treea9b278f2d124c1db1261bc5128516fff3ea89919 /sw
parentafed3d177b8bfbc98d631867f200486bc2963e03 (diff)
clang-tidy misc-redundant-expression
Change-Id: I708b0b486a233071f95592ccdb97f27fc35a23c4 Reviewed-on: https://gerrit.libreoffice.org/61783 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/doc/htmltbl.cxx2
-rw-r--r--sw/source/filter/ww8/ww8par2.cxx2
-rw-r--r--sw/source/ui/fldui/fldvar.cxx2
3 files changed, 3 insertions, 3 deletions
diff --git a/sw/source/core/doc/htmltbl.cxx b/sw/source/core/doc/htmltbl.cxx
index 0fe3775b2b4a..f82d8bb706d3 100644
--- a/sw/source/core/doc/htmltbl.cxx
+++ b/sw/source/core/doc/htmltbl.cxx
@@ -1026,7 +1026,7 @@ void SwHTMLTableLayout::AutoLayoutPass1()
pColumn->SetMax( pColumn->GetMin() );
}
// and divide by the quotient
- SAL_WARN_IF(nQuotMax != ULONG_MAX && !nQuotMax, "sw.core", "Where did the relative columns go?");
+ SAL_WARN_IF(!nQuotMax, "sw.core", "Where did the relative columns go?");
for (i = 0; i < m_nCols; ++i)
{
SwHTMLTableLayoutColumn *pColumn = GetColumn( i );
diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx
index 02f90c9123fb..29343e0d092f 100644
--- a/sw/source/filter/ww8/ww8par2.cxx
+++ b/sw/source/filter/ww8/ww8par2.cxx
@@ -753,7 +753,7 @@ void SwWW8ImplReader::Read_ANLevelNo( sal_uInt16, const sal_uInt8* pData, short
{
// Range WW:1..9 -> SW:0..8 no bullets / numbering
- if (*pData <= MAXLEVEL && *pData <= 9)
+ if (*pData <= 9)
{
m_nSwNumLevel = *pData - 1;
if (!m_bNoAttrImport)
diff --git a/sw/source/ui/fldui/fldvar.cxx b/sw/source/ui/fldui/fldvar.cxx
index 3886a510694a..4f38ce446a76 100644
--- a/sw/source/ui/fldui/fldvar.cxx
+++ b/sw/source/ui/fldui/fldvar.cxx
@@ -797,7 +797,7 @@ void SwFieldVarPage::FillFormatLB(sal_uInt16 nTypeId)
{
if (!nOldNumFormat && (nNumFormatSel = m_pNumFormatLB->GetEntryPos(sOldNumSel)) != LISTBOX_ENTRY_NOTFOUND)
m_pNumFormatLB->SelectEntryPos(nNumFormatSel);
- else if (nOldNumFormat && nOldNumFormat == NUMBERFORMAT_ENTRY_NOT_FOUND)
+ else if (nOldNumFormat == NUMBERFORMAT_ENTRY_NOT_FOUND)
m_pNumFormatLB->SelectEntry(sOldSel);
}