From 25fc5f91ab7e6fd410ccd403ba19741a16eaab49 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Fri, 17 Sep 2021 13:37:42 +0200 Subject: [API CHANGE] Deprecate css.registry.XSimpleRegistry::mergeKey ...and let its implementations just throw a RuntimeException, now that regmerge has been removed in "[API CHANGE] Remove deprecated idlc and regmerge from the SDK". Deprecate css.registry.MergeConflictException along with it (though stoc/source/implementationregistration/ still uses it internally). And remove the previously unused include/registry/writer.hxx along with the newly unused include/registry/writer.h, RegistryTypeWriter, and RegistryTypeReader. Change-Id: I10fd286617975dc0ef9f74460a3a3eab8060939d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123615 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- registry/source/registry.cxx | 50 -------------------------------------------- 1 file changed, 50 deletions(-) (limited to 'registry/source/registry.cxx') diff --git a/registry/source/registry.cxx b/registry/source/registry.cxx index 1727dfc119dc..a58a79c8bb76 100644 --- a/registry/source/registry.cxx +++ b/registry/source/registry.cxx @@ -213,55 +213,6 @@ static RegError REGISTRY_CALLTYPE destroyRegistry(RegHandle hReg, } -// mergeKey - -static RegError REGISTRY_CALLTYPE mergeKey(RegHandle hReg, - RegKeyHandle hKey, - rtl_uString* keyName, - rtl_uString* regFileName, - sal_Bool bWarnings, - sal_Bool bReport) -{ - 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; - - if (keyName->length) - { - ORegKey* pNewKey = nullptr; - RegError _ret = pKey->createKey(OUString::unacquired(&keyName), reinterpret_cast(&pNewKey)); - if (_ret != RegError::NO_ERROR) - return _ret; - - _ret = pReg->loadKey(pNewKey, regFileName, bWarnings, bReport); - if (_ret != RegError::NO_ERROR && (_ret != RegError::MERGE_CONFLICT || bWarnings)) - { - if (pNewKey != pKey) - (void) pKey->closeKey(pNewKey); - else - (void) pKey->releaseKey(pNewKey); - return _ret; - } - - return (pNewKey != pKey) ? pKey->closeKey(pNewKey) : pKey->releaseKey(pNewKey); - } - - return pReg->loadKey(pKey, regFileName, bWarnings, bReport); -} - - // dumpRegistry static RegError REGISTRY_CALLTYPE dumpRegistry(RegHandle hReg, @@ -298,7 +249,6 @@ Registry_Api* REGISTRY_CALLTYPE initRegistry_Api() &openRegistry, &closeRegistry, &destroyRegistry, - &mergeKey, &acquireKey, &releaseKey, &isKeyReadOnly, -- cgit