summaryrefslogtreecommitdiff
path: root/ucb/source/ucp/hierarchy/hierarchyprovider.cxx
diff options
context:
space:
mode:
authorKai Sommerfeld <kso@openoffice.org>2000-12-21 08:31:52 +0000
committerKai Sommerfeld <kso@openoffice.org>2000-12-21 08:31:52 +0000
commitf22f3967e0f8cd0691648f4a23914bd98f011d10 (patch)
tree2d68a8fa10e2ca1fa8cadbc810e663f731ec74a8 /ucb/source/ucp/hierarchy/hierarchyprovider.cxx
parent76c92d6c36b3c09c4eaa38fd742296c0c2f66243 (diff)
#82494# - Workaround to reduce CPU load in case config data are broken.
Diffstat (limited to 'ucb/source/ucp/hierarchy/hierarchyprovider.cxx')
-rw-r--r--ucb/source/ucp/hierarchy/hierarchyprovider.cxx17
1 files changed, 14 insertions, 3 deletions
diff --git a/ucb/source/ucp/hierarchy/hierarchyprovider.cxx b/ucb/source/ucp/hierarchy/hierarchyprovider.cxx
index 1e8de1f93f68..fab14ee3d1bb 100644
--- a/ucb/source/ucp/hierarchy/hierarchyprovider.cxx
+++ b/ucb/source/ucp/hierarchy/hierarchyprovider.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: hierarchyprovider.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: kso $ $Date: 2000-12-10 15:13:51 $
+ * last change: $Author: kso $ $Date: 2000-12-21 09:31:52 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -100,7 +100,8 @@ using namespace hierarchy_ucp;
HierarchyContentProvider::HierarchyContentProvider(
const Reference< XMultiServiceFactory >& rXSMgr )
-: ::ucb::ContentProviderImplHelper( rXSMgr )
+: ::ucb::ContentProviderImplHelper( rXSMgr ),
+ m_bTriedToGetRootReadAccess( sal_False )
{
}
@@ -268,6 +269,14 @@ HierarchyContentProvider::getRootConfigReadNameAccess()
vos::OGuard aGuard( m_aMutex );
if ( !m_xRootConfigReadNameAccess.is() )
{
+ if ( m_bTriedToGetRootReadAccess ) // #82494#
+ {
+ OSL_ENSURE( sal_False,
+ "HierarchyContentProvider::getRootConfigReadNameAccess - "
+ "Unable to read any config data! -> #82494#" );
+ return Reference< XHierarchicalNameAccess >();
+ }
+
try
{
getConfigProvider();
@@ -278,6 +287,8 @@ HierarchyContentProvider::getRootConfigReadNameAccess()
aArguments[ 0 ] <<= OUString::createFromAscii(
"/org.openoffice.ucb.Hierarchy/Root" );
+ m_bTriedToGetRootReadAccess = sal_True;
+
m_xRootConfigReadNameAccess
= Reference< XHierarchicalNameAccess >(
m_xConfigProvider->createInstanceWithArguments(