connectivity/source/drivers/macab/MacabRecord.cxx | 2 -- stoc/source/defaultregistry/defaultregistry.cxx | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-)
New commits: commit d8feeecfec0753b566183d30d935bd389a9c9515 Author: Julien Nabet <[email protected]> AuthorDate: Tue Nov 26 18:40:04 2019 +0100 Commit: Julien Nabet <[email protected]> CommitDate: Tue Nov 26 23:31:56 2019 +0100 Fix for 2 commits related to cppcheck: 1) https://cgit.freedesktop.org/libreoffice/core/commit/?id=4e1ae2a9a0d2d9185b49677fa4ea2a2b1fe8bab2 I had let "size" and "fields" initialized twice instead of initializing only 2) https://cgit.freedesktop.org/libreoffice/core/commit/?id=e6ab01ce532d1db01579b70bd476b2f643522bf9 put back original order for NestedKeyImpl and adjust initialization accordingly Change-Id: I6ca4e6520558011c359f8ea089b6d431ad79edfe Reviewed-on: https://gerrit.libreoffice.org/83810 Tested-by: Jenkins Reviewed-by: Julien Nabet <[email protected]> diff --git a/connectivity/source/drivers/macab/MacabRecord.cxx b/connectivity/source/drivers/macab/MacabRecord.cxx index b7e270f378f2..3072e1eaa2f4 100644 --- a/connectivity/source/drivers/macab/MacabRecord.cxx +++ b/connectivity/source/drivers/macab/MacabRecord.cxx @@ -42,8 +42,6 @@ MacabRecord::MacabRecord(const sal_Int32 _size) : size(_size), fields(std::make_unique<macabfield *[]>(size)) { - size = _size; - fields = std::make_unique<macabfield *[]>(size); sal_Int32 i; for(i = 0; i < size; i++) fields[i] = nullptr; diff --git a/stoc/source/defaultregistry/defaultregistry.cxx b/stoc/source/defaultregistry/defaultregistry.cxx index 8667ebc9f205..92adf4642938 100644 --- a/stoc/source/defaultregistry/defaultregistry.cxx +++ b/stoc/source/defaultregistry/defaultregistry.cxx @@ -127,8 +127,8 @@ protected: OUString computeName(const OUString& name); OUString m_name; - rtl::Reference<NestedRegistryImpl> m_xRegistry; sal_uInt32 m_state; + rtl::Reference<NestedRegistryImpl> m_xRegistry; Reference<XRegistryKey> m_localKey; Reference<XRegistryKey> m_defaultKey; }; @@ -137,7 +137,7 @@ protected: NestedKeyImpl::NestedKeyImpl( NestedRegistryImpl* pDefaultRegistry, Reference<XRegistryKey>& localKey, Reference<XRegistryKey>& defaultKey ) - : m_xRegistry(pDefaultRegistry), m_state(m_xRegistry->m_state), m_localKey(localKey), m_defaultKey(defaultKey) + : m_state(pDefaultRegistry->m_state), m_xRegistry(pDefaultRegistry), m_localKey(localKey), m_defaultKey(defaultKey) { if (m_localKey.is()) { _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
