diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-07-28 09:01:19 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-07-28 16:52:06 +0200 |
commit | e8493f9349d18cbcb323930a9bf200c542a72d62 (patch) | |
tree | a682aeb0343b0379a2a9d2d9ea39a7f096115050 /svl | |
parent | ff41cf1b8dbeb36b8824257acb5c5ba272415108 (diff) |
loplugin:collapseif
Change-Id: I69bfafa97c66ef944cc6ae35c7e2f66d0430d6a4
Reviewed-on: https://gerrit.libreoffice.org/76496
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svl')
-rw-r--r-- | svl/source/misc/inethist.cxx | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/svl/source/misc/inethist.cxx b/svl/source/misc/inethist.cxx index 5dafe30d2ce2..19cae51df5ad 100644 --- a/svl/source/misc/inethist.cxx +++ b/svl/source/misc/inethist.cxx @@ -254,16 +254,10 @@ void INetURLHistory_Impl::putUrl (const OUString &rUrl) // Check source and destination. sal_uInt16 nDI = std::min (k, sal_uInt16(capacity() - 1)); - if (nSI < nDI) - { - if (!(m_pHash[nDI] < h)) - nDI -= 1; - } - if (nDI < nSI) - { - if (m_pHash[nDI] < h) - nDI += 1; - } + if (nSI < nDI && !(m_pHash[nDI] < h)) + nDI -= 1; + if (nDI < nSI && m_pHash[nDI] < h) + nDI += 1; // Assign data. m_pList[m_aHead.m_nNext].m_nHash = m_pHash[nSI].m_nHash = h; |