diff options
author | Caolán McNamara <caolanm@redhat.com> | 2017-11-08 15:47:50 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-11-09 00:16:43 +0100 |
commit | 9cb2962197b592a9b93dac2ea8b8f3652cb5fbcb (patch) | |
tree | b995c09768d5c3c2e89c08d7833c8b4669cf112e /unotools | |
parent | f5765d9f621bdc8fd0e1ac5eec1dcab9ae5b5d06 (diff) |
rename AvoidConfig to Fuzzing
cause that's what its really used for and a couple of cases
are not specifically about avoiding config but avoiding uninteresting
disk acccess and what not
Change-Id: I4c6454f98388579fcd0bf9798321d30408ab65ee
Reviewed-on: https://gerrit.libreoffice.org/44491
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'unotools')
-rw-r--r-- | unotools/source/config/configitem.cxx | 4 | ||||
-rw-r--r-- | unotools/source/config/configmgr.cxx | 10 | ||||
-rw-r--r-- | unotools/source/config/eventcfg.cxx | 2 | ||||
-rw-r--r-- | unotools/source/config/fontcfg.cxx | 4 | ||||
-rw-r--r-- | unotools/source/config/saveopt.cxx | 2 | ||||
-rw-r--r-- | unotools/source/config/securityoptions.cxx | 2 | ||||
-rw-r--r-- | unotools/source/config/syslocaleoptions.cxx | 2 | ||||
-rw-r--r-- | unotools/source/config/viewoptions.cxx | 2 | ||||
-rw-r--r-- | unotools/source/misc/mediadescriptor.cxx | 2 |
9 files changed, 15 insertions, 15 deletions
diff --git a/unotools/source/config/configitem.cxx b/unotools/source/config/configitem.cxx index 80d18841299e..1a2b9f7d11d1 100644 --- a/unotools/source/config/configitem.cxx +++ b/unotools/source/config/configitem.cxx @@ -157,7 +157,7 @@ ConfigItem::ConfigItem(const OUString &rSubTree, ConfigItemMode nSetMode ) : m_bEnableInternalNotification(false), m_nInValueChange(0) { - if (utl::ConfigManager::IsAvoidConfig()) + if (utl::ConfigManager::IsFuzzing()) return; if (nSetMode & ConfigItemMode::ReleaseTree) @@ -1113,7 +1113,7 @@ void ConfigItem::ClearModified() Reference< XHierarchicalNameAccess> ConfigItem::GetTree() { Reference< XHierarchicalNameAccess> xRet; - if (utl::ConfigManager::IsAvoidConfig()) + if (utl::ConfigManager::IsFuzzing()) return xRet; if(!m_xHierarchyAccess.is()) xRet = ConfigManager::acquireTree(*this); diff --git a/unotools/source/config/configmgr.cxx b/unotools/source/config/configmgr.cxx index 5dd1dc7ee3f8..417bfc311bbf 100644 --- a/unotools/source/config/configmgr.cxx +++ b/unotools/source/config/configmgr.cxx @@ -195,16 +195,16 @@ void utl::ConfigManager::doStoreConfigItems() { } } -static bool bIsAvoidConfig = false; +static bool bIsFuzzing = false; -bool utl::ConfigManager::IsAvoidConfig() +bool utl::ConfigManager::IsFuzzing() { - return bIsAvoidConfig; + return bIsFuzzing; } -void utl::ConfigManager::EnableAvoidConfig() +void utl::ConfigManager::EnableFuzzing() { - bIsAvoidConfig = true; + bIsFuzzing = true; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/unotools/source/config/eventcfg.cxx b/unotools/source/config/eventcfg.cxx index b998e820f28b..12b99a2db9cc 100644 --- a/unotools/source/config/eventcfg.cxx +++ b/unotools/source/config/eventcfg.cxx @@ -396,7 +396,7 @@ Mutex& GlobalEventConfig::GetOwnStaticMutex() OUString GlobalEventConfig::GetEventName( GlobalEventId nIndex ) { - if (utl::ConfigManager::IsAvoidConfig()) + if (utl::ConfigManager::IsFuzzing()) return OUString(); rtl::Reference<GlobalEventConfig> createImpl(new GlobalEventConfig); return GlobalEventConfig::m_pImpl->GetEventName( nIndex ); diff --git a/unotools/source/config/fontcfg.cxx b/unotools/source/config/fontcfg.cxx index 0e4dac43ce2d..38751cd7a912 100644 --- a/unotools/source/config/fontcfg.cxx +++ b/unotools/source/config/fontcfg.cxx @@ -99,7 +99,7 @@ DefaultFontConfiguration& DefaultFontConfiguration::get() DefaultFontConfiguration::DefaultFontConfiguration() { - if (utl::ConfigManager::IsAvoidConfig()) + if (utl::ConfigManager::IsFuzzing()) return; // create configuration hierarchical access name try @@ -352,7 +352,7 @@ FontSubstConfiguration& FontSubstConfiguration::get() FontSubstConfiguration::FontSubstConfiguration() : maSubstHash( 300 ) { - if (utl::ConfigManager::IsAvoidConfig()) + if (utl::ConfigManager::IsFuzzing()) return; try { diff --git a/unotools/source/config/saveopt.cxx b/unotools/source/config/saveopt.cxx index 7fa55766aa5b..cdb66c6fabe4 100644 --- a/unotools/source/config/saveopt.cxx +++ b/unotools/source/config/saveopt.cxx @@ -557,7 +557,7 @@ SvtSaveOptions_Impl::SvtSaveOptions_Impl() } } - if (!utl::ConfigManager::IsAvoidConfig()) + if (!utl::ConfigManager::IsFuzzing()) { bAutoSave = officecfg::Office::Recovery::AutoSave::Enabled::get(); nAutoSaveTime = officecfg::Office::Recovery::AutoSave::TimeIntervall::get(); diff --git a/unotools/source/config/securityoptions.cxx b/unotools/source/config/securityoptions.cxx index de9c0dcc2dfc..3e928de6709c 100644 --- a/unotools/source/config/securityoptions.cxx +++ b/unotools/source/config/securityoptions.cxx @@ -284,7 +284,7 @@ void SvtSecurityOptions_Impl::SetProperty( sal_Int32 nProperty, const Any& rValu { m_seqSecureURLs.realloc( 0 ); rValue >>= m_seqSecureURLs; - if (!utl::ConfigManager::IsAvoidConfig()) + if (!utl::ConfigManager::IsFuzzing()) { SvtPathOptions aOpt; sal_uInt32 nCount = m_seqSecureURLs.getLength(); diff --git a/unotools/source/config/syslocaleoptions.cxx b/unotools/source/config/syslocaleoptions.cxx index 4eadf6d3aa54..5f9b744c3d27 100644 --- a/unotools/source/config/syslocaleoptions.cxx +++ b/unotools/source/config/syslocaleoptions.cxx @@ -542,7 +542,7 @@ SvtSysLocaleOptions::SvtSysLocaleOptions() { pImpl = std::make_shared<SvtSysLocaleOptions_Impl>(); g_pSysLocaleOptions = pImpl; - if (!utl::ConfigManager::IsAvoidConfig()) + if (!utl::ConfigManager::IsFuzzing()) ItemHolder1::holdConfigItem(EItem::SysLocaleOptions); } pImpl->AddListener(this); diff --git a/unotools/source/config/viewoptions.cxx b/unotools/source/config/viewoptions.cxx index 0332e94718ac..a4c49a4a3373 100644 --- a/unotools/source/config/viewoptions.cxx +++ b/unotools/source/config/viewoptions.cxx @@ -149,7 +149,7 @@ SvtViewOptionsBase_Impl::SvtViewOptionsBase_Impl( const OUString& sList ) , m_nWriteCount( 0 ) #endif { - if (utl::ConfigManager::IsAvoidConfig()) + if (utl::ConfigManager::IsFuzzing()) return; try diff --git a/unotools/source/misc/mediadescriptor.cxx b/unotools/source/misc/mediadescriptor.cxx index b9b4610012c3..5bb5660afcf8 100644 --- a/unotools/source/misc/mediadescriptor.cxx +++ b/unotools/source/misc/mediadescriptor.cxx @@ -484,7 +484,7 @@ bool MediaDescriptor::addInputStream() /*-----------------------------------------------*/ bool MediaDescriptor::addInputStreamOwnLock() { - const bool bLock = !utl::ConfigManager::IsAvoidConfig() + const bool bLock = !utl::ConfigManager::IsFuzzing() && officecfg::Office::Common::Misc::UseDocumentSystemFileLocking::get(); return impl_addInputStream(bLock); } |