diff options
author | Noel Grandin <noel@peralex.com> | 2015-11-24 14:24:21 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-11-25 08:25:09 +0200 |
commit | a78182a993288680b04d1329536af5953e8ca31c (patch) | |
tree | 7684e9845b142adbc58cc5bf63003aad7c597593 | |
parent | fa452b54a5d2b31d5bc57617323f0f1092d0794f (diff) |
loplugin:unusedfields in include/package,include/registry
Change-Id: Iadba30885ba3bab7aaee58e298a9dc6b22c8b977
-rw-r--r-- | include/package/Deflater.hxx | 1 | ||||
-rw-r--r-- | include/registry/registry.hxx | 3 | ||||
-rw-r--r-- | package/source/zipapi/Deflater.cxx | 1 | ||||
-rw-r--r-- | registry/source/registry.cxx | 94 |
4 files changed, 0 insertions, 99 deletions
diff --git a/include/package/Deflater.hxx b/include/package/Deflater.hxx index 00e3ee81246e..640c6d4828a5 100644 --- a/include/package/Deflater.hxx +++ b/include/package/Deflater.hxx @@ -35,7 +35,6 @@ protected: css::uno::Sequence< sal_Int8 > sInBuffer; bool bFinish; bool bFinished; - sal_Int32 nStrategy; sal_Int64 nOffset, nLength; z_stream* pStream; diff --git a/include/registry/registry.hxx b/include/registry/registry.hxx index 76ffe26df0c1..dbbe0f1eab8a 100644 --- a/include/registry/registry.hxx +++ b/include/registry/registry.hxx @@ -43,10 +43,7 @@ struct Registry_Api RegError (REGISTRY_CALLTYPE *openRegistry) (rtl_uString*, RegHandle*, RegAccessMode); RegError (REGISTRY_CALLTYPE *closeRegistry) (RegHandle); RegError (REGISTRY_CALLTYPE *destroyRegistry) (RegHandle, rtl_uString*); - RegError (REGISTRY_CALLTYPE *loadKey) (RegHandle, RegKeyHandle, rtl_uString*, rtl_uString*); - RegError (REGISTRY_CALLTYPE *saveKey) (RegHandle, RegKeyHandle, rtl_uString*, rtl_uString*); RegError (REGISTRY_CALLTYPE *mergeKey) (RegHandle, RegKeyHandle, rtl_uString*, rtl_uString*, sal_Bool, sal_Bool); - RegError (REGISTRY_CALLTYPE *dumpRegistry) (RegHandle, RegKeyHandle); void (REGISTRY_CALLTYPE *acquireKey) (RegKeyHandle); void (REGISTRY_CALLTYPE *releaseKey) (RegKeyHandle); sal_Bool (REGISTRY_CALLTYPE *isKeyReadOnly) (RegKeyHandle); diff --git a/package/source/zipapi/Deflater.cxx b/package/source/zipapi/Deflater.cxx index ccff8c6a2edb..ce3df035b612 100644 --- a/package/source/zipapi/Deflater.cxx +++ b/package/source/zipapi/Deflater.cxx @@ -60,7 +60,6 @@ void Deflater::init (sal_Int32 nLevelArg, sal_Int32 nStrategyArg, bool bNowrap) Deflater::Deflater(sal_Int32 nSetLevel, bool bNowrap) : bFinish(false) , bFinished(false) -, nStrategy(DEFAULT_STRATEGY) , nOffset(0) , nLength(0) { diff --git a/registry/source/registry.cxx b/registry/source/registry.cxx index b18fa570badb..fed98584c645 100644 --- a/registry/source/registry.cxx +++ b/registry/source/registry.cxx @@ -236,97 +236,6 @@ static RegError REGISTRY_CALLTYPE destroyRegistry(RegHandle hReg, -// loadRegKey - -static RegError REGISTRY_CALLTYPE loadKey(RegHandle hReg, - RegKeyHandle hKey, - rtl_uString* keyName, - rtl_uString* regFileName) -{ - - ORegistry* pReg = static_cast< ORegistry* >(hReg); - if (!pReg) - return RegError::INVALID_REGISTRY; - - if (!pReg->isOpen()) - return RegError::REGISTRY_NOT_OPEN; - - ORegKey* pKey = static_cast< ORegKey* >(hKey); - if (!pKey) - return RegError::INVALID_KEY; - - if (pKey->getRegistry() != pReg) - return RegError::INVALID_KEY; - if (pKey->isDeleted()) - return RegError::INVALID_KEY; - if (pKey->isReadOnly()) - return RegError::REGISTRY_READONLY; - - - ORegKey* pNewKey = nullptr; - RegError _ret = pKey->openKey(keyName, reinterpret_cast<RegKeyHandle*>(&pNewKey)); - if (_ret == RegError::NO_ERROR) - { - pKey->releaseKey(pNewKey); - pKey->deleteKey(keyName); - } - - _ret = pKey->createKey(keyName, reinterpret_cast<RegKeyHandle*>(&pNewKey)); - if (_ret != RegError::NO_ERROR) - return _ret; - - _ret = pReg->loadKey(pNewKey, regFileName); - if (_ret != RegError::NO_ERROR) - { - pKey->releaseKey(pNewKey); - pKey->deleteKey(keyName); - return _ret; - } - - return pKey->closeKey(pNewKey); -} - - -// saveKey - -static RegError REGISTRY_CALLTYPE saveKey(RegHandle hReg, - RegKeyHandle hKey, - rtl_uString* keyName, - rtl_uString* regFileName) -{ - - ORegistry* pReg = static_cast< ORegistry* >(hReg); - if (!pReg) - return RegError::INVALID_REGISTRY; - - if (!pReg->isOpen()) - return RegError::REGISTRY_NOT_OPEN; - - ORegKey* pKey = static_cast< ORegKey* >(hKey); - if (!pKey) - return RegError::INVALID_KEY; - - if (pKey->getRegistry() != pReg) - return RegError::INVALID_KEY; - if (pKey->isDeleted()) - return RegError::INVALID_KEY; - - ORegKey* pNewKey = nullptr; - RegError _ret = pKey->openKey(keyName, reinterpret_cast<RegKeyHandle*>(&pNewKey)); - if (_ret != RegError::NO_ERROR) - return _ret; - - _ret = pReg->saveKey(pNewKey, regFileName); - if (_ret != RegError::NO_ERROR) - { - (void) pKey->releaseKey(pNewKey); - return _ret; - } - - return pKey->releaseKey(pNewKey); -} - - // mergeKey static RegError REGISTRY_CALLTYPE mergeKey(RegHandle hReg, @@ -412,10 +321,7 @@ Registry_Api* REGISTRY_CALLTYPE initRegistry_Api() &openRegistry, &closeRegistry, &destroyRegistry, - &loadKey, - &saveKey, &mergeKey, - &dumpRegistry, &acquireKey, &releaseKey, &isKeyReadOnly, |