diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-04-14 16:40:35 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-04-15 08:37:34 +0200 |
commit | 897493fbd34a1bd10320767b48cbf04d422f89b3 (patch) | |
tree | 6d35dd000343e533cf6b3eef2f816533bea4b048 /ucb/source/ucp/webdav-neon | |
parent | 7facde27194b866e589eada3f5657b0b5c69efb0 (diff) |
loplugin:sequentialassign in ucb..vbahelper
Change-Id: I0fff9ee06225d4ff2e9c0611b1b11f1d3b896be2
Reviewed-on: https://gerrit.libreoffice.org/70733
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'ucb/source/ucp/webdav-neon')
-rw-r--r-- | ucb/source/ucp/webdav-neon/DAVTypes.cxx | 12 | ||||
-rw-r--r-- | ucb/source/ucp/webdav-neon/PropfindCache.cxx | 6 | ||||
-rw-r--r-- | ucb/source/ucp/webdav-neon/webdavcontent.cxx | 3 |
3 files changed, 7 insertions, 14 deletions
diff --git a/ucb/source/ucp/webdav-neon/DAVTypes.cxx b/ucb/source/ucp/webdav-neon/DAVTypes.cxx index 2cd4ec27ef11..6cf4a01b304a 100644 --- a/ucb/source/ucp/webdav-neon/DAVTypes.cxx +++ b/ucb/source/ucp/webdav-neon/DAVTypes.cxx @@ -107,8 +107,7 @@ bool DAVOptionsCache::getDAVOptions( const OUString & rURL, DAVOptions & rDAVOpt normalizeURLLastChar( aEncodedUrl ); // search the URL in the static map - DAVOptionsMap::iterator it; - it = m_aTheCache.find( aEncodedUrl ); + DAVOptionsMap::iterator it = m_aTheCache.find( aEncodedUrl ); if ( it == m_aTheCache.end() ) return false; else @@ -134,8 +133,7 @@ void DAVOptionsCache::removeDAVOptions( const OUString & rURL ) OUString aEncodedUrl( ucb_impl::urihelper::encodeURI( NeonUri::unescape( rURL ) ) ); normalizeURLLastChar( aEncodedUrl ); - DAVOptionsMap::iterator it; - it = m_aTheCache.find( aEncodedUrl ); + DAVOptionsMap::iterator it = m_aTheCache.find( aEncodedUrl ); if ( it != m_aTheCache.end() ) { m_aTheCache.erase( it ); @@ -156,8 +154,7 @@ void DAVOptionsCache::addDAVOptions( DAVOptions & rDAVOptions, const sal_uInt32 rDAVOptions.setRedirectedURL( aRedirURL ); // check if already cached - DAVOptionsMap::iterator it; - it = m_aTheCache.find( aEncodedUrl ); + DAVOptionsMap::iterator it = m_aTheCache.find( aEncodedUrl ); if ( it != m_aTheCache.end() ) { // already in cache, check LifeTime if ( (*it).second.getRequestedTimeLife() == nLifeTime ) @@ -177,8 +174,7 @@ void DAVOptionsCache::setHeadAllowed( const OUString & rURL, const bool HeadAllo OUString aEncodedUrl( ucb_impl::urihelper::encodeURI( NeonUri::unescape( rURL ) ) ); normalizeURLLastChar( aEncodedUrl ); - DAVOptionsMap::iterator it; - it = m_aTheCache.find( aEncodedUrl ); + DAVOptionsMap::iterator it = m_aTheCache.find( aEncodedUrl ); if ( it != m_aTheCache.end() ) { // first check for stale diff --git a/ucb/source/ucp/webdav-neon/PropfindCache.cxx b/ucb/source/ucp/webdav-neon/PropfindCache.cxx index 546c6c8545f7..a54003661ec0 100644 --- a/ucb/source/ucp/webdav-neon/PropfindCache.cxx +++ b/ucb/source/ucp/webdav-neon/PropfindCache.cxx @@ -43,8 +43,7 @@ namespace webdav_ucp { // search the URL in the static map osl::MutexGuard aGuard( m_aMutex ); - PropNameCache::const_iterator it; - it = m_aTheCache.find( rURL ); + PropNameCache::const_iterator it = m_aTheCache.find( rURL ); if ( it == m_aTheCache.end() ) return false; else @@ -67,8 +66,7 @@ namespace webdav_ucp void PropertyNamesCache::removeCachedPropertyNames( const OUString& rURL ) { osl::MutexGuard aGuard( m_aMutex ); - PropNameCache::const_iterator it; - it = m_aTheCache.find( rURL ); + PropNameCache::const_iterator it = m_aTheCache.find( rURL ); if ( it != m_aTheCache.end() ) { m_aTheCache.erase( it ); diff --git a/ucb/source/ucp/webdav-neon/webdavcontent.cxx b/ucb/source/ucp/webdav-neon/webdavcontent.cxx index 8ef0956b2eff..9c139fb4a30d 100644 --- a/ucb/source/ucp/webdav-neon/webdavcontent.cxx +++ b/ucb/source/ucp/webdav-neon/webdavcontent.cxx @@ -2403,8 +2403,7 @@ void Content::queryChildren( ContentRefList& rChildren ) if ( ( aChildURL.getLength() > nLen ) && ( aChildURL.startsWith( aURL ) ) ) { - sal_Int32 nPos = nLen; - nPos = aChildURL.indexOf( '/', nPos ); + sal_Int32 nPos = aChildURL.indexOf( '/', nLen ); if ( ( nPos == -1 ) || ( nPos == ( aChildURL.getLength() - 1 ) ) ) |