diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-09-30 15:11:25 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-10-01 10:51:39 +0200 |
commit | b74c4b7c675883e23bea9fd52682ae89d36539f6 (patch) | |
tree | 6d2a521470e37ae99a7977aaa129700151c7f43b /registry | |
parent | 46c2a3688c9ee7f558f75cbe856c26c4b8849b7e (diff) |
loplugin:stringadd in package..sax
Change-Id: I1f8b626ae99bca6e31e7c4aa9c8a1fc016b76e5c
Reviewed-on: https://gerrit.libreoffice.org/79890
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'registry')
-rw-r--r-- | registry/source/keyimpl.cxx | 27 | ||||
-rw-r--r-- | registry/source/regimpl.cxx | 6 |
2 files changed, 11 insertions, 22 deletions
diff --git a/registry/source/keyimpl.cxx b/registry/source/keyimpl.cxx index e5aef0675199..d969cbaa32c5 100644 --- a/registry/source/keyimpl.cxx +++ b/registry/source/keyimpl.cxx @@ -228,8 +228,7 @@ RegError ORegKey::getValueInfo(const OUString& valueName, RegValueType* pValueTy accessMode = storeAccessMode::ReadOnly; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); @@ -288,8 +287,7 @@ RegError ORegKey::setValue(const OUString& valueName, RegValueType vType, RegVal return RegError::INVALID_VALUE; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); @@ -355,8 +353,7 @@ RegError ORegKey::setLongListValue(const OUString& valueName, sal_Int32 const * return RegError::REGISTRY_READONLY; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); @@ -411,8 +408,7 @@ RegError ORegKey::setStringListValue(const OUString& valueName, sal_Char** pValu return RegError::REGISTRY_READONLY; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); @@ -476,8 +472,7 @@ RegError ORegKey::setUnicodeListValue(const OUString& valueName, sal_Unicode** p return RegError::REGISTRY_READONLY; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); @@ -544,8 +539,7 @@ RegError ORegKey::getValue(const OUString& valueName, RegValue value) const accessMode = storeAccessMode::ReadOnly; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); @@ -630,8 +624,7 @@ RegError ORegKey::getLongListValue(const OUString& valueName, sal_Int32** pValue accessMode = storeAccessMode::ReadOnly; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); @@ -734,8 +727,7 @@ RegError ORegKey::getStringListValue(const OUString& valueName, sal_Char*** pVal accessMode = storeAccessMode::ReadOnly; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); @@ -832,8 +824,7 @@ RegError ORegKey::getUnicodeListValue(const OUString& valueName, sal_Unicode*** accessMode = storeAccessMode::ReadOnly; } - OUString sImplValueName( VALUE_PREFIX ); - sImplValueName += valueName; + OUString sImplValueName = VALUE_PREFIX + valueName; REG_GUARD(m_pRegistry->m_mutex); diff --git a/registry/source/regimpl.cxx b/registry/source/regimpl.cxx index 63c937a1109a..ab7dcb09888e 100644 --- a/registry/source/regimpl.cxx +++ b/registry/source/regimpl.cxx @@ -796,8 +796,7 @@ RegError ORegistry::eraseKey(ORegKey* pKey, const OUString& keyName) return _ret; } - OUString tmpName(sRelativKey); - tmpName += ROOT; + OUString tmpName = sRelativKey + ROOT; OStoreFile sFile(pKey->getStoreFile()); if (sFile.isValid() && sFile.remove(sFullPath, tmpName)) @@ -1198,8 +1197,7 @@ RegError ORegistry::loadAndSaveKeys(ORegKey* pTargetKey, if (sRelPath.getLength() > 1 || sFullPath.isEmpty()) sFullPath += ROOT; - OUString sFullKeyName = sFullPath; - sFullKeyName += keyName; + OUString sFullKeyName = sFullPath + keyName; OStoreDirectory rStoreDir; if (rStoreDir.create(pTargetKey->getStoreFile(), sFullPath, keyName, storeAccessMode::Create)) |