From 877da827a7aab5a7fb6bc3f84c2d5a48cac381ff Mon Sep 17 00:00:00 2001 From: Takeshi Abe Date: Tue, 6 Dec 2011 00:19:44 +0900 Subject: catch exception by constant reference --- desktop/source/app/app.cxx | 60 ++++----- desktop/source/app/appfirststart.cxx | 4 +- desktop/source/app/check_ext_deps.cxx | 14 +-- desktop/source/app/langselect.cxx | 12 +- desktop/source/app/officeipcthread.cxx | 2 +- desktop/source/app/userinstall.cxx | 4 +- desktop/source/deployment/dp_log.cxx | 4 +- desktop/source/deployment/gui/dp_gui_dialog2.cxx | 14 +-- .../deployment/gui/dp_gui_extensioncmdqueue.cxx | 24 ++-- .../source/deployment/gui/dp_gui_extlistbox.cxx | 6 +- desktop/source/deployment/gui/dp_gui_service.cxx | 6 +- desktop/source/deployment/gui/dp_gui_theextmgr.cxx | 22 ++-- .../source/deployment/gui/dp_gui_updatedialog.cxx | 10 +- .../deployment/gui/dp_gui_updateinstalldialog.cxx | 4 +- .../deployment/manager/dp_extensionmanager.cxx | 134 ++++++++++----------- desktop/source/deployment/manager/dp_manager.cxx | 94 +++++++-------- .../source/deployment/manager/dp_managerfac.cxx | 2 +- .../deployment/misc/dp_descriptioninfoset.cxx | 50 ++++---- desktop/source/deployment/misc/dp_misc.cxx | 2 +- desktop/source/deployment/misc/dp_ucb.cxx | 14 +-- desktop/source/deployment/misc/dp_update.cxx | 8 +- .../registry/component/dp_compbackenddb.cxx | 4 +- .../deployment/registry/component/dp_component.cxx | 16 +-- .../registry/configuration/dp_configuration.cxx | 6 +- .../configuration/dp_configurationbackenddb.cxx | 12 +- desktop/source/deployment/registry/dp_backend.cxx | 36 +++--- .../source/deployment/registry/dp_backenddb.cxx | 32 ++--- desktop/source/deployment/registry/dp_registry.cxx | 2 +- .../source/deployment/registry/help/dp_help.cxx | 2 +- .../deployment/registry/help/dp_helpbackenddb.cxx | 8 +- .../registry/package/dp_extbackenddb.cxx | 4 +- .../deployment/registry/package/dp_package.cxx | 46 +++---- .../migration/services/oo3extensionmigration.cxx | 18 +-- desktop/source/offacc/acceptor.cxx | 4 +- desktop/source/pkgchk/unopkg/unopkg_app.cxx | 18 +-- desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx | 2 +- desktop/test/deployment/active/active_native.cxx | 2 +- 37 files changed, 351 insertions(+), 351 deletions(-) (limited to 'desktop') diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx index 1c5a66ad9239..9e9f65604021 100644 --- a/desktop/source/app/app.cxx +++ b/desktop/source/app/app.cxx @@ -774,7 +774,7 @@ void Desktop::DeInit() OfficeIPCThread::DisableOfficeIPCThread(); if( pSignalHandler ) osl_removeSignalHandler( pSignalHandler ); - } catch (RuntimeException&) { + } catch (const RuntimeException&) { // someone threw an exception during shutdown // this will leave some garbage behind.. } @@ -790,7 +790,7 @@ sal_Bool Desktop::QueryExit() utl::ConfigManager::storeConfigItems(); RTL_LOGFILE_CONTEXT_TRACE( aLog, "<- store config items" ); } - catch ( RuntimeException& ) + catch ( const RuntimeException& ) { } @@ -826,7 +826,7 @@ sal_Bool Desktop::QueryExit() // it also looks to be threadsafe OfficeIPCThread::DisableOfficeIPCThread(); } - catch ( RuntimeException& ) + catch ( const RuntimeException& ) { } @@ -1788,14 +1788,14 @@ int Desktop::Main() } } } - catch ( com::sun::star::lang::WrappedTargetException& wte ) + catch ( const com::sun::star::lang::WrappedTargetException& wte ) { com::sun::star::uno::Exception te; wte.TargetException >>= te; FatalError( MakeStartupConfigAccessErrorMessage(wte.Message + te.Message) ); return EXIT_FAILURE; } - catch ( com::sun::star::uno::Exception& e ) + catch ( const com::sun::star::uno::Exception& e ) { FatalError( MakeStartupErrorMessage(e.Message) ); return EXIT_FAILURE; @@ -1835,7 +1835,7 @@ int Desktop::Main() xDesktop->addTerminateListener( new OfficeIPCThreadController ); SetSplashScreenProgress(100); } - catch ( com::sun::star::uno::Exception& e ) + catch ( const com::sun::star::uno::Exception& e ) { FatalError( MakeStartupErrorMessage(e.Message) ); return EXIT_FAILURE; @@ -1971,23 +1971,23 @@ bool Desktop::InitializeConfiguration() comphelper::getProcessComponentContext() ); return true; } - catch( ::com::sun::star::lang::ServiceNotRegisteredException& ) + catch( const ::com::sun::star::lang::ServiceNotRegisteredException& ) { this->HandleBootstrapErrors( Desktop::BE_UNO_SERVICE_CONFIG_MISSING ); } - catch( ::com::sun::star::configuration::MissingBootstrapFileException& e ) + catch( const ::com::sun::star::configuration::MissingBootstrapFileException& e ) { OUString aMsg( CreateErrorMsgString( utl::Bootstrap::MISSING_BOOTSTRAP_FILE, e.BootstrapFileURL )); HandleBootstrapPathErrors( ::utl::Bootstrap::INVALID_USER_INSTALL, aMsg ); } - catch( ::com::sun::star::configuration::InvalidBootstrapFileException& e ) + catch( const ::com::sun::star::configuration::InvalidBootstrapFileException& e ) { OUString aMsg( CreateErrorMsgString( utl::Bootstrap::INVALID_BOOTSTRAP_FILE_ENTRY, e.BootstrapFileURL )); HandleBootstrapPathErrors( ::utl::Bootstrap::INVALID_BASE_INSTALL, aMsg ); } - catch( ::com::sun::star::configuration::InstallationIncompleteException& ) + catch( const ::com::sun::star::configuration::InstallationIncompleteException& ) { OUString aVersionFileURL; OUString aMsg; @@ -1999,27 +1999,27 @@ bool Desktop::InitializeConfiguration() HandleBootstrapPathErrors( ::utl::Bootstrap::MISSING_USER_INSTALL, aMsg ); } - catch ( com::sun::star::configuration::backend::BackendAccessException& exception) + catch ( const com::sun::star::configuration::backend::BackendAccessException& exception) { // [cm122549] It is assumed in this case that the message // coming from InitConfiguration (in fact CreateApplicationConf...) // is suitable for display directly. FatalError( MakeStartupErrorMessage( exception.Message ) ); } - catch ( com::sun::star::configuration::backend::BackendSetupException& exception) + catch ( const com::sun::star::configuration::backend::BackendSetupException& exception) { // [cm122549] It is assumed in this case that the message // coming from InitConfiguration (in fact CreateApplicationConf...) // is suitable for display directly. FatalError( MakeStartupErrorMessage( exception.Message ) ); } - catch ( ::com::sun::star::configuration::CannotLoadConfigurationException& ) + catch ( const ::com::sun::star::configuration::CannotLoadConfigurationException& ) { OUString aMsg( CreateErrorMsgString( utl::Bootstrap::INVALID_BOOTSTRAP_DATA, OUString() )); HandleBootstrapPathErrors( ::utl::Bootstrap::INVALID_BASE_INSTALL, aMsg ); } - catch( ::com::sun::star::uno::Exception& ) + catch( const ::com::sun::star::uno::Exception& ) { OUString aMsg( CreateErrorMsgString( utl::Bootstrap::INVALID_BOOTSTRAP_DATA, OUString() )); @@ -2082,7 +2082,7 @@ sal_Bool Desktop::InitializeQuickstartMode( Reference< XMultiServiceFactory >& r } return sal_True; } - catch( ::com::sun::star::uno::Exception& ) + catch( const ::com::sun::star::uno::Exception& ) { return sal_False; } @@ -2215,7 +2215,7 @@ void Desktop::PreloadModuleData( const CommandLineArgs& rArgs ) ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_blank")), 0, args ), UNO_QUERY_THROW ); xDoc->close( sal_False ); } - catch ( com::sun::star::uno::Exception& ) + catch ( const com::sun::star::uno::Exception& ) { } } @@ -2227,7 +2227,7 @@ void Desktop::PreloadModuleData( const CommandLineArgs& rArgs ) ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_blank")), 0, args ), UNO_QUERY_THROW ); xDoc->close( sal_False ); } - catch ( com::sun::star::uno::Exception& ) + catch ( const com::sun::star::uno::Exception& ) { } } @@ -2239,7 +2239,7 @@ void Desktop::PreloadModuleData( const CommandLineArgs& rArgs ) ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_blank")), 0, args ), UNO_QUERY_THROW ); xDoc->close( sal_False ); } - catch ( com::sun::star::uno::Exception& ) + catch ( const com::sun::star::uno::Exception& ) { } } @@ -2251,7 +2251,7 @@ void Desktop::PreloadModuleData( const CommandLineArgs& rArgs ) ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_blank")), 0, args ), UNO_QUERY_THROW ); xDoc->close( sal_False ); } - catch ( com::sun::star::uno::Exception& ) + catch ( const com::sun::star::uno::Exception& ) { } } @@ -2284,7 +2284,7 @@ void Desktop::PreloadConfigurationData() xCmdAccess->getByName( DEFINE_CONST_UNICODE( ".uno:EditGlossary" )); } } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } @@ -2295,7 +2295,7 @@ void Desktop::PreloadConfigurationData() if ( xCmdAccess.is() ) xCmdAccess->getByName( DEFINE_CONST_UNICODE( ".uno:InsertObjectStarMath" )); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } @@ -2307,7 +2307,7 @@ void Desktop::PreloadConfigurationData() if ( xCmdAccess.is() ) xCmdAccess->getByName( DEFINE_CONST_UNICODE( ".uno:Polygon" )); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } } @@ -2326,7 +2326,7 @@ void Desktop::PreloadConfigurationData() if ( xWindowAccess.is() ) xWindowAccess->getByName( DEFINE_CONST_UNICODE( "private:resource/toolbar/standardbar" )); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } try @@ -2336,7 +2336,7 @@ void Desktop::PreloadConfigurationData() if ( xWindowAccess.is() ) xWindowAccess->getByName( DEFINE_CONST_UNICODE( "private:resource/toolbar/standardbar" )); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } try @@ -2346,7 +2346,7 @@ void Desktop::PreloadConfigurationData() if ( xWindowAccess.is() ) xWindowAccess->getByName( DEFINE_CONST_UNICODE( "private:resource/toolbar/standardbar" )); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } try @@ -2356,7 +2356,7 @@ void Desktop::PreloadConfigurationData() if ( xWindowAccess.is() ) xWindowAccess->getByName( DEFINE_CONST_UNICODE( "private:resource/toolbar/standardbar" )); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } } @@ -2373,7 +2373,7 @@ void Desktop::PreloadConfigurationData() { aSeqSeqPropValue = xUIElementFactory->getRegisteredFactories(); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } } @@ -2392,7 +2392,7 @@ void Desktop::PreloadConfigurationData() DEFINE_CONST_UNICODE( ".uno:CharFontName" ), OUString() ); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } } @@ -2407,7 +2407,7 @@ void Desktop::PreloadConfigurationData() { aSeq = xNameAccess->getElementNames(); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } } @@ -2421,7 +2421,7 @@ void Desktop::PreloadConfigurationData() { aSeq = xNameAccess->getElementNames(); } - catch ( ::com::sun::star::uno::Exception& ) + catch ( const ::com::sun::star::uno::Exception& ) { } } diff --git a/desktop/source/app/appfirststart.cxx b/desktop/source/app/appfirststart.cxx index 8adb26b76a7b..e558ecf73668 100644 --- a/desktop/source/app/appfirststart.cxx +++ b/desktop/source/app/appfirststart.cxx @@ -85,7 +85,7 @@ void Desktop::DoRestartActionsIfNecessary( sal_Bool bQuickStart ) xQuickstart->initialize( aSeq ); } } - catch( uno::Exception& ) + catch( const uno::Exception& ) { // this is no critical operation so it should not prevent office from starting } @@ -101,7 +101,7 @@ void Desktop::SetRestartState() xPSet->setPropertyValue( sPropName, makeAny( sal_True ) ); Reference< util::XChangesBatch >( xPSet, UNO_QUERY_THROW )->commitChanges(); } - catch( uno::Exception& ) + catch( const uno::Exception& ) { // this is no critical operation, ignore the exception } diff --git a/desktop/source/app/check_ext_deps.cxx b/desktop/source/app/check_ext_deps.cxx index 5a837d7305f7..7b3578a1eab0 100644 --- a/desktop/source/app/check_ext_deps.cxx +++ b/desktop/source/app/check_ext_deps.cxx @@ -258,10 +258,10 @@ static bool impl_checkDependencies( const uno::Reference< uno::XComponentContext xAllPackages = xExtensionManager->getAllExtensions( uno::Reference< task::XAbortChannel >(), uno::Reference< ucb::XCommandEnvironment >() ); } - catch ( deployment::DeploymentException & ) { return true; } - catch ( ucb::CommandFailedException & ) { return true; } - catch ( ucb::CommandAbortedException & ) { return true; } - catch ( lang::IllegalArgumentException & e ) { + catch ( const deployment::DeploymentException & ) { return true; } + catch ( const ucb::CommandFailedException & ) { return true; } + catch ( const ucb::CommandAbortedException & ) { return true; } + catch ( const lang::IllegalArgumentException & e ) { throw uno::RuntimeException( e.Message, e.Context ); } @@ -294,8 +294,8 @@ static bool impl_checkDependencies( const uno::Reference< uno::XComponentContext else bRegistered = false; } - catch ( uno::RuntimeException & ) { throw; } - catch ( uno::Exception & exc) { + catch ( const uno::RuntimeException & ) { throw; } + catch (const uno::Exception & exc) { (void) exc; OSL_FAIL( ::rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); } @@ -306,7 +306,7 @@ static bool impl_checkDependencies( const uno::Reference< uno::XComponentContext try { bDependenciesValid = xPackage->checkDependencies( uno::Reference< ucb::XCommandEnvironment >() ); } - catch ( deployment::DeploymentException & ) {} + catch ( const deployment::DeploymentException & ) {} if ( ! bDependenciesValid ) { return false; diff --git a/desktop/source/app/langselect.cxx b/desktop/source/app/langselect.cxx index 5b11e01588df..f502cc82a2ad 100644 --- a/desktop/source/app/langselect.cxx +++ b/desktop/source/app/langselect.cxx @@ -159,7 +159,7 @@ bool LanguageSelection::prepareLanguage() xLocaleProp->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("Locale"))) >>= usLocale; setDefaultLanguage(usLocale); } - catch (Exception&) + catch (const Exception&) { m_eStatus = LS_STATUS_CONFIGURATIONACCESS_BROKEN; } @@ -246,11 +246,11 @@ bool LanguageSelection::prepareLanguage() bSuccess = sal_True; } - catch ( PropertyVetoException& ) + catch ( const PropertyVetoException& ) { // we are not allowed to change this } - catch (Exception& e) + catch (const Exception& e) { OString aMsg = OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US); OSL_FAIL(aMsg.getStr()); @@ -373,7 +373,7 @@ Reference< XNameAccess > LanguageSelection::getConfigAccess(const sal_Char* pPat xNameAccess = Reference< XNameAccess > ( theConfigProvider->createInstanceWithArguments( sAccessSrvc, theArgs ), UNO_QUERY_THROW ); - } catch (com::sun::star::uno::Exception& e) + } catch (const com::sun::star::uno::Exception& e) { OString aMsg = OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US); OSL_FAIL(aMsg.getStr()); @@ -519,11 +519,11 @@ void LanguageSelection::resetUserLanguage() xProp->setPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("UILocale")), makeAny(OUString())); Reference< XChangesBatch >(xProp, UNO_QUERY_THROW)->commitChanges(); } - catch ( PropertyVetoException& ) + catch ( const PropertyVetoException& ) { // we are not allowed to change this } - catch ( Exception& e) + catch (const Exception& e) { OString aMsg = OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US); OSL_FAIL(aMsg.getStr()); diff --git a/desktop/source/app/officeipcthread.cxx b/desktop/source/app/officeipcthread.cxx index 6f819aab813d..2b03f5822718 100644 --- a/desktop/source/app/officeipcthread.cxx +++ b/desktop/source/app/officeipcthread.cxx @@ -699,7 +699,7 @@ void SAL_CALL OfficeIPCThread::run() Parser p( aArguments ); aCmdLineArgs.reset( new CommandLineArgs( p ) ); } - catch ( CommandLineArgs::Supplier::Exception & ) + catch ( const CommandLineArgs::Supplier::Exception & ) { #if (OSL_DEBUG_LEVEL > 1) || defined DBG_UTIL fprintf( stderr, "Error in received command line arguments\n" ); diff --git a/desktop/source/app/userinstall.cxx b/desktop/source/app/userinstall.cxx index 174d84474c5e..4815558c8808 100644 --- a/desktop/source/app/userinstall.cxx +++ b/desktop/source/app/userinstall.cxx @@ -267,11 +267,11 @@ namespace desktop { hpset->setHierarchicalPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM("Office/ooSetupInstCompleted")), makeAny(sal_True)); Reference< XChangesBatch >(hpset, UNO_QUERY_THROW)->commitChanges(); } - catch ( PropertyVetoException& ) + catch ( const PropertyVetoException& ) { // we are not allowed to change this } - catch (Exception& e) + catch (const Exception& e) { OString aMsg("create_user_install(): "); aMsg += OUStringToOString(e.Message, RTL_TEXTENCODING_ASCII_US); diff --git a/desktop/source/deployment/dp_log.cxx b/desktop/source/deployment/dp_log.cxx index 079670b5c236..63ab7cb7cefe 100644 --- a/desktop/source/deployment/dp_log.cxx +++ b/desktop/source/deployment/dp_log.cxx @@ -85,7 +85,7 @@ void ProgressLogImpl::disposing() m_xLogFile.clear(); } } - catch (Exception & exc) { + catch (const Exception & exc) { (void) exc; OSL_FAIL( OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); @@ -149,7 +149,7 @@ void ProgressLogImpl::log_write( OString const & text ) text.getLength() ) ); } } - catch (io::IOException & exc) { + catch (const io::IOException & exc) { (void) exc; OSL_FAIL( OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.cxx b/desktop/source/deployment/gui/dp_gui_dialog2.cxx index 23430b76a0c2..58e719af09f9 100644 --- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx +++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx @@ -636,7 +636,7 @@ void DialogHelper::openWebBrowser( const OUString & sURL, const OUString &sTitle //throws css::lang::IllegalArgumentException, css::system::SystemShellExecuteException xSystemShellExecute->execute( sURL, OUString(), SystemShellExecuteFlags::DEFAULTS ); } - catch ( uno::Exception& ) + catch ( const uno::Exception& ) { uno::Any exc( ::cppu::getCaughtException() ); OUString msg( ::comphelper::anyToString( exc ) ); @@ -976,7 +976,7 @@ uno::Sequence< OUString > ExtMgrDialog::raiseAddPicker() try { xFilterManager->appendFilter( iPos->first, iPos->second ); } - catch (lang::IllegalArgumentException & exc) { + catch (const lang::IllegalArgumentException & exc) { OSL_FAIL( ::rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); (void) exc; @@ -1002,7 +1002,7 @@ IMPL_LINK( ExtMgrDialog, HandleCancelBtn, void*, EMPTYARG ) { m_xAbortChannel->sendAbort(); } - catch ( uno::RuntimeException & ) + catch ( const uno::RuntimeException & ) { OSL_FAIL( "### unexpected RuntimeException!" ); } @@ -1451,7 +1451,7 @@ IMPL_LINK( UpdateRequiredDialog, HandleCancelBtn, void*, EMPTYARG ) { m_xAbortChannel->sendAbort(); } - catch ( uno::RuntimeException & ) + catch ( const uno::RuntimeException & ) { OSL_FAIL( "### unexpected RuntimeException!" ); } @@ -1758,8 +1758,8 @@ bool UpdateRequiredDialog::isEnabled( const uno::Reference< deployment::XPackage else bRegistered = false; } - catch ( uno::RuntimeException & ) { throw; } - catch ( uno::Exception & exc) { + catch ( const uno::RuntimeException & ) { throw; } + catch (const uno::Exception & exc) { (void) exc; OSL_FAIL( ::rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); bRegistered = false; @@ -1777,7 +1777,7 @@ bool UpdateRequiredDialog::checkDependencies( const uno::Reference< deployment:: try { bDependenciesValid = xPackage->checkDependencies( uno::Reference< ucb::XCommandEnvironment >() ); } - catch ( deployment::DeploymentException & ) {} + catch ( const deployment::DeploymentException & ) {} if ( ! bDependenciesValid ) { return false; diff --git a/desktop/source/deployment/gui/dp_gui_extensioncmdqueue.cxx b/desktop/source/deployment/gui/dp_gui_extensioncmdqueue.cxx index 60b03bfac683..dfce37cb20a7 100644 --- a/desktop/source/deployment/gui/dp_gui_extensioncmdqueue.cxx +++ b/desktop/source/deployment/gui/dp_gui_extensioncmdqueue.cxx @@ -805,7 +805,7 @@ void ExtensionCmdQueue::Thread::execute() break; } } - catch ( ucb::CommandAbortedException & ) + catch ( const ucb::CommandAbortedException & ) { //This exception is thrown when the user clicks cancel on the progressbar. //Then we cancel the installation of all extensions and remove them from @@ -817,7 +817,7 @@ void ExtensionCmdQueue::Thread::execute() } break; } - catch ( ucb::CommandFailedException & ) + catch ( const ucb::CommandFailedException & ) { //This exception is thrown when a user clicked cancel in the messagebox which was //startet by the interaction handler. For example the user will be asked if he/she @@ -826,7 +826,7 @@ void ExtensionCmdQueue::Thread::execute() //with installing the remaining extensions. continue; } - catch ( uno::Exception & ) + catch ( const uno::Exception & ) { //Todo display the user an error //see also DialogImpl::SyncPushButton::Click() @@ -884,7 +884,7 @@ void ExtensionCmdQueue::Thread::_addExtension( ::rtl::Reference< ProgressCmdEnv { anyTitle = ::ucbhelper::Content( rPackageURL, rCmdEnv.get() ).getPropertyValue( OUSTR("Title") ); } - catch ( uno::Exception & ) + catch ( const uno::Exception & ) { return; } @@ -907,12 +907,12 @@ void ExtensionCmdQueue::Thread::_addExtension( ::rtl::Reference< ProgressCmdEnv xExtMgr->addExtension(rPackageURL, uno::Sequence(), rRepository, xAbortChannel, rCmdEnv.get() ); } - catch ( ucb::CommandFailedException & ) + catch ( const ucb::CommandFailedException & ) { // When the extension is already installed we'll get a dialog asking if we want to overwrite. If we then press // cancel this exception is thrown. } - catch ( ucb::CommandAbortedException & ) + catch ( const ucb::CommandAbortedException & ) { // User clicked the cancel button // TODO: handle cancel @@ -934,11 +934,11 @@ void ExtensionCmdQueue::Thread::_removeExtension( ::rtl::Reference< ProgressCmdE { xExtMgr->removeExtension( id, xPackage->getName(), xPackage->getRepositoryName(), xAbortChannel, rCmdEnv.get() ); } - catch ( deployment::DeploymentException & ) + catch ( const deployment::DeploymentException & ) {} - catch ( ucb::CommandFailedException & ) + catch ( const ucb::CommandFailedException & ) {} - catch ( ucb::CommandAbortedException & ) + catch ( const ucb::CommandAbortedException & ) {} // Check, if there are still updates to be notified via menu bar icon @@ -1018,7 +1018,7 @@ void ExtensionCmdQueue::Thread::_enableExtension( ::rtl::Reference< ProgressCmdE if ( m_pDialogHelper ) m_pDialogHelper->updatePackageInfo( xPackage ); } - catch ( ::ucb::CommandAbortedException & ) + catch ( const ::ucb::CommandAbortedException & ) {} } @@ -1040,7 +1040,7 @@ void ExtensionCmdQueue::Thread::_disableExtension( ::rtl::Reference< ProgressCmd if ( m_pDialogHelper ) m_pDialogHelper->updatePackageInfo( xPackage ); } - catch ( ::ucb::CommandAbortedException & ) + catch ( const ::ucb::CommandAbortedException & ) {} } @@ -1062,7 +1062,7 @@ void ExtensionCmdQueue::Thread::_acceptLicense( ::rtl::Reference< ProgressCmdEnv if ( m_pDialogHelper ) m_pDialogHelper->updatePackageInfo( xPackage ); } - catch ( ::ucb::CommandAbortedException & ) + catch ( const ::ucb::CommandAbortedException & ) {} } diff --git a/desktop/source/deployment/gui/dp_gui_extlistbox.cxx b/desktop/source/deployment/gui/dp_gui_extlistbox.cxx index 4095f62e47d3..ed2757c2e9db 100644 --- a/desktop/source/deployment/gui/dp_gui_extlistbox.cxx +++ b/desktop/source/deployment/gui/dp_gui_extlistbox.cxx @@ -96,8 +96,8 @@ Entry_Impl::Entry_Impl( const uno::Reference< deployment::XPackage > &xPackage, else if ( eState == NOT_REGISTERED ) checkDependencies(); } - catch (deployment::ExtensionRemovedException &) {} - catch (uno::RuntimeException &) {} + catch (const deployment::ExtensionRemovedException &) {} + catch (const uno::RuntimeException &) {} } //------------------------------------------------------------------------------ @@ -129,7 +129,7 @@ void Entry_Impl::checkDependencies() try { m_xPackage->checkDependencies( uno::Reference< ucb::XCommandEnvironment >() ); } - catch ( deployment::DeploymentException &e ) + catch ( const deployment::DeploymentException &e ) { deployment::DependencyException depExc; if ( e.Cause >>= depExc ) diff --git a/desktop/source/deployment/gui/dp_gui_service.cxx b/desktop/source/deployment/gui/dp_gui_service.cxx index 7197fe465e27..8108e74bda6c 100644 --- a/desktop/source/deployment/gui/dp_gui_service.cxx +++ b/desktop/source/deployment/gui/dp_gui_service.cxx @@ -171,11 +171,11 @@ ServiceImpl::ServiceImpl( Sequence const& args, try { comphelper::unwrapArgs( args, m_parent, m_view, m_unopkg ); return; - } catch (css::lang::IllegalArgumentException & ) { + } catch ( const css::lang::IllegalArgumentException & ) { } try { comphelper::unwrapArgs( args, m_extensionURL); - } catch (css::lang::IllegalArgumentException & ) { + } catch ( const css::lang::IllegalArgumentException & ) { } ResHookProc pProc = ResMgr::GetReadStringHook(); @@ -216,7 +216,7 @@ void ServiceImpl::startExecuteModal( try { bOfficePipePresent = dp_misc::office_is_running(); } - catch (Exception & exc) { + catch (const Exception & exc) { if (bAppUp) { const SolarMutexGuard guard; std::auto_ptr box( diff --git a/desktop/source/deployment/gui/dp_gui_theextmgr.cxx b/desktop/source/deployment/gui/dp_gui_theextmgr.cxx index aed5ee5c5637..322e9e847048 100644 --- a/desktop/source/deployment/gui/dp_gui_theextmgr.cxx +++ b/desktop/source/deployment/gui/dp_gui_theextmgr.cxx @@ -95,7 +95,7 @@ TheExtensionManager::TheExtensionManager( Window *pParent, uno::Any value = xNameAccessRepositories->getByName( OUSTR( "WebsiteLink" ) ); m_sGetExtensionsURL = value.get< OUString > (); } - catch ( uno::Exception& ) + catch ( const uno::Exception& ) {} if ( dp_misc::office_is_running() ) @@ -210,13 +210,13 @@ bool TheExtensionManager::checkUpdates( bool /* bShowUpdateOnly */, bool /*bPare try { xAllPackages = m_xExtensionManager->getAllExtensions( uno::Reference< task::XAbortChannel >(), uno::Reference< ucb::XCommandEnvironment >() ); - } catch ( deployment::DeploymentException & ) { + } catch ( const deployment::DeploymentException & ) { return false; - } catch ( ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { return false; - } catch ( ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { return false; - } catch ( lang::IllegalArgumentException & e ) { + } catch ( const lang::IllegalArgumentException & e ) { throw uno::RuntimeException( e.Message, e.Context ); } @@ -292,13 +292,13 @@ void TheExtensionManager::createPackageList() try { xAllPackages = m_xExtensionManager->getAllExtensions( uno::Reference< task::XAbortChannel >(), uno::Reference< ucb::XCommandEnvironment >() ); - } catch ( deployment::DeploymentException & ) { + } catch ( const deployment::DeploymentException & ) { return; - } catch ( ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { return; - } catch ( ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { return; - } catch ( lang::IllegalArgumentException & e ) { + } catch ( const lang::IllegalArgumentException & e ) { throw uno::RuntimeException( e.Message, e.Context ); } @@ -352,10 +352,10 @@ PackageState TheExtensionManager::getPackageState( const uno::Reference< deploym else return NOT_AVAILABLE; } - catch ( uno::RuntimeException & ) { + catch ( const uno::RuntimeException & ) { throw; } - catch ( uno::Exception & exc) { + catch (const uno::Exception & exc) { (void) exc; OSL_FAIL( ::rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); return NOT_AVAILABLE; diff --git a/desktop/source/deployment/gui/dp_gui_updatedialog.cxx b/desktop/source/deployment/gui/dp_gui_updatedialog.cxx index a61e663cfdca..b8dabbb63493 100644 --- a/desktop/source/deployment/gui/dp_gui_updatedialog.cxx +++ b/desktop/source/deployment/gui/dp_gui_updatedialog.cxx @@ -348,10 +348,10 @@ void UpdateDialog::Thread::execute() extensions = extMgr->getExtensionsWithSameIdentifier( dp_misc::getIdentifier(info.extension), info.extension->getName(), uno::Reference()); - } catch (lang::IllegalArgumentException& ) { + } catch ( const lang::IllegalArgumentException& ) { OSL_ASSERT(0); continue; - } catch (css::ucb::CommandFailedException& ) { + } catch ( const css::ucb::CommandFailedException& ) { OSL_ASSERT(0); continue; } @@ -573,9 +573,9 @@ UpdateDialog::UpdateDialog( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.awt.Toolkit")), m_context)), uno::UNO_QUERY_THROW); - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; - } catch (uno::Exception & e) { + } catch (const uno::Exception & e) { throw uno::RuntimeException(e.Message, e.Context); } m_updates.SetSelectHdl(LINK(this, UpdateDialog, selectionHandler)); @@ -1427,7 +1427,7 @@ IMPL_LINK( UpdateDialog, hyperlink_clicked, svt::FixedHyperlink*, pHyperlink ) xSystemShellExecute->execute( sURL, ::rtl::OUString(), com::sun::star::system::SystemShellExecuteFlags::DEFAULTS); } - catch (uno::Exception& ) + catch ( const uno::Exception& ) { } diff --git a/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx b/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx index e262a1c3915a..6df09e0317e9 100644 --- a/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx +++ b/desktop/source/deployment/gui/dp_gui_updateinstalldialog.cxx @@ -367,7 +367,7 @@ void UpdateInstallDialog::Thread::downloadExtensions() try { dp_misc::create_folder(0, destFolder, m_updateCmdEnv.get(), true ); - } catch (cssu::Exception & e) + } catch (const cssu::Exception & e) { throw cssu::Exception(e.Message + OUSTR(" No extensions will be installed."), 0); } @@ -446,7 +446,7 @@ void UpdateInstallDialog::Thread::downloadExtensions() } } - catch (cssu::Exception & e) + catch (const cssu::Exception & e) { SolarMutexGuard g; if (m_stop) { diff --git a/desktop/source/deployment/manager/dp_extensionmanager.cxx b/desktop/source/deployment/manager/dp_extensionmanager.cxx index 44fa2653b373..a5082dafdab9 100644 --- a/desktop/source/deployment/manager/dp_extensionmanager.cxx +++ b/desktop/source/deployment/manager/dp_extensionmanager.cxx @@ -301,7 +301,7 @@ void ExtensionManager::addExtensionsToMap( xPackage = lRepos[i]->getDeployedPackage( identifier, fileName, Reference()); } - catch(lang::IllegalArgumentException &) + catch(const lang::IllegalArgumentException &) { // thrown if the extension does not exist in this repository } @@ -343,15 +343,15 @@ ExtensionManager::getExtensionsWithSameIdentifier( ::std::list > > (listExtensions); } - catch (deploy::DeploymentException & ) + catch ( const deploy::DeploymentException & ) { throw; } - catch ( ucb::CommandFailedException & ) + catch ( const ucb::CommandFailedException & ) { throw; } - catch (lang::IllegalArgumentException &) + catch (const lang::IllegalArgumentException &) { throw; } @@ -371,7 +371,7 @@ bool ExtensionManager::isUserDisabled( try { listExtensions = getExtensionsWithSameId(identifier, fileName); - } catch (lang::IllegalArgumentException & ) { + } catch ( const lang::IllegalArgumentException & ) { } OSL_ASSERT(listExtensions.size() == 3); @@ -426,7 +426,7 @@ void ExtensionManager::activateExtension( ::std::list > listExtensions; try { listExtensions = getExtensionsWithSameId(identifier, fileName); - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { } OSL_ASSERT(listExtensions.size() == 3); @@ -558,7 +558,7 @@ bool ExtensionManager::doChecksForAddExtension( sIdentifier, sFileName, xCmdEnv); out_existingExtension = xOldExtension; } - catch (lang::IllegalArgumentException &) + catch (const lang::IllegalArgumentException &) { } bool bCanInstall = false; @@ -605,17 +605,17 @@ bool ExtensionManager::doChecksForAddExtension( return bCanInstall; } - catch (deploy::DeploymentException& ) { + catch ( const deploy::DeploymentException& ) { throw; - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { throw; - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { throw; - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { throw; - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; - } catch (uno::Exception &) { + } catch (const uno::Exception &) { uno::Any excOccurred = ::cppu::getCaughtException(); deploy::DeploymentException exc( OUSTR("Extension Manager: exception in doChecksForAddExtension"), @@ -713,7 +713,7 @@ Reference ExtensionManager::addExtension( xTmpExtension = xExtensionBackup; OSL_ASSERT(xTmpExtension.is()); } - catch (lang::DisposedException &) + catch (const lang::DisposedException &) { //Another thread might have removed the extension meanwhile } @@ -761,15 +761,15 @@ Reference ExtensionManager::addExtension( static_cast(this), uno::Any()); } } - catch (deploy::DeploymentException& ) { + catch ( const deploy::DeploymentException& ) { excOccurred2 = ::cppu::getCaughtException(); - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { excOccurred2 = ::cppu::getCaughtException(); - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { excOccurred2 = ::cppu::getCaughtException(); - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { excOccurred2 = ::cppu::getCaughtException(); - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { excOccurred2 = ::cppu::getCaughtException(); } catch (...) { excOccurred2 = ::cppu::getCaughtException(); @@ -811,17 +811,17 @@ Reference ExtensionManager::addExtension( { fireModified(); - }catch (deploy::DeploymentException& ) { + }catch ( const deploy::DeploymentException& ) { throw; - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { throw; - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { throw; - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { throw; - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; - } catch (uno::Exception &) { + } catch (const uno::Exception &) { uno::Any excOccurred = ::cppu::getCaughtException(); deploy::DeploymentException exc( OUSTR("Extension Manager: exception in doChecksForAddExtension"), @@ -881,15 +881,15 @@ void ExtensionManager::removeExtension( xAbortChannel, xCmdEnv); fireModified(); } - catch (deploy::DeploymentException& ) { + catch ( const deploy::DeploymentException& ) { excOccurred1 = ::cppu::getCaughtException(); - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { excOccurred1 = ::cppu::getCaughtException(); - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { excOccurred1 = ::cppu::getCaughtException(); - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { excOccurred1 = ::cppu::getCaughtException(); - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { excOccurred1 = ::cppu::getCaughtException(); } catch (...) { excOccurred1 = ::cppu::getCaughtException(); @@ -967,15 +967,15 @@ void ExtensionManager::enableExtension( extension->getName(), false, false, xAbortChannel, xCmdEnv); } - catch (deploy::DeploymentException& ) { + catch ( const deploy::DeploymentException& ) { excOccurred = ::cppu::getCaughtException(); - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { excOccurred = ::cppu::getCaughtException(); - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { excOccurred = ::cppu::getCaughtException(); - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { excOccurred = ::cppu::getCaughtException(); - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { excOccurred = ::cppu::getCaughtException(); } catch (...) { excOccurred = ::cppu::getCaughtException(); @@ -1032,15 +1032,15 @@ sal_Int32 ExtensionManager::checkPrerequisitesAndEnable( xAbortChannel, xCmdEnv); return ret; } - catch (deploy::DeploymentException& ) { + catch ( const deploy::DeploymentException& ) { throw; - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { throw; - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { throw; - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { throw; - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; } catch (...) { uno::Any excOccurred = ::cppu::getCaughtException(); @@ -1080,15 +1080,15 @@ void ExtensionManager::disableExtension( activateExtension(id, extension->getName(), true, false, xAbortChannel, xCmdEnv); } - catch (deploy::DeploymentException& ) { + catch ( const deploy::DeploymentException& ) { excOccurred = ::cppu::getCaughtException(); - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { excOccurred = ::cppu::getCaughtException(); - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { excOccurred = ::cppu::getCaughtException(); - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { excOccurred = ::cppu::getCaughtException(); - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { excOccurred = ::cppu::getCaughtException(); } catch (...) { excOccurred = ::cppu::getCaughtException(); @@ -1187,15 +1187,15 @@ uno::Sequence< uno::Sequence > > } return seqSeq; - } catch (deploy::DeploymentException& ) { + } catch ( const deploy::DeploymentException& ) { throw; - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { throw; - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { throw; - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { throw; - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; } catch (...) { uno::Any exc = ::cppu::getCaughtException(); @@ -1236,19 +1236,19 @@ void ExtensionManager::reinstallDeployedExtensions( OSL_ASSERT(id.getLength()); activateExtension(id, fileName, false, true, xAbortChannel, xCmdEnv ); } - catch (lang::DisposedException &) + catch (const lang::DisposedException &) { } } - } catch (deploy::DeploymentException& ) { + } catch ( const deploy::DeploymentException& ) { throw; - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { throw; - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { throw; - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { throw; - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; } catch (...) { uno::Any exc = ::cppu::getCaughtException(); @@ -1298,15 +1298,15 @@ void ExtensionManager::synchronizeBundledPrereg( "$BUNDLED_EXTENSIONS_PREREG/lastsynchronized")); writeLastModified(lastSyncBundled, xCmdEnv); - } catch (deploy::DeploymentException& ) { + } catch ( const deploy::DeploymentException& ) { throw; - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { throw; - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { throw; - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { throw; - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; } catch (...) { uno::Any exc = ::cppu::getCaughtException(); @@ -1375,15 +1375,15 @@ sal_Bool ExtensionManager::synchronize( "$SHARED_EXTENSIONS_USER/lastsynchronized")); writeLastModified(lastSyncShared, xCmdEnv); return bModified; - } catch (deploy::DeploymentException& ) { + } catch ( const deploy::DeploymentException& ) { throw; - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { throw; - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { throw; - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { throw; - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; } catch (...) { uno::Any exc = ::cppu::getCaughtException(); @@ -1520,7 +1520,7 @@ bool singleton_entries( xKey->setStringValue( serviceDecl.getSupportedServiceNames()[0] ); return true; } - catch (registry::InvalidRegistryException & exc) { + catch (const registry::InvalidRegistryException & exc) { (void) exc; // avoid warnings OSL_FAIL( ::rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); diff --git a/desktop/source/deployment/manager/dp_manager.cxx b/desktop/source/deployment/manager/dp_manager.cxx index 62f27b22c7fe..508d6bb45707 100644 --- a/desktop/source/deployment/manager/dp_manager.cxx +++ b/desktop/source/deployment/manager/dp_manager.cxx @@ -428,7 +428,7 @@ Reference PackageManagerImpl::create( that->m_readOnly = false; erase_path( stampURL, xCmdEnv ); } - catch (RuntimeException &) { + catch (const RuntimeException &) { try { erase_path( stampURL, xCmdEnv ); } catch (...) @@ -436,7 +436,7 @@ Reference PackageManagerImpl::create( } throw; } - catch (Exception &) { + catch (const Exception &) { that->m_readOnly = true; } } @@ -460,10 +460,10 @@ Reference PackageManagerImpl::create( return xPackageManager; } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); ::rtl::OUStringBuffer buf; buf.appendAscii( RTL_CONSTASCII_STRINGPARAM("[context=\"") ); @@ -508,10 +508,10 @@ void PackageManagerImpl::disposing() t_pm_helper::disposing(); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); throw lang::WrappedTargetRuntimeException( OUSTR("caught unexpected exception while disposing..."), @@ -599,7 +599,7 @@ OUString PackageManagerImpl::detectMediaType( try { ucbContent.getPropertyValue( OUSTR("MediaType") ) >>= mediaType; } - catch (beans::UnknownPropertyException &) { + catch (const beans::UnknownPropertyException &) { } OSL_ENSURE( mediaType.getLength() > 0, "### no media-type?!" ); } @@ -615,7 +615,7 @@ OUString PackageManagerImpl::detectMediaType( if (xPackageType.is()) mediaType = xPackageType->getMediaType(); } - catch (lang::IllegalArgumentException & exc) { + catch (const lang::IllegalArgumentException & exc) { if (throw_exc) throw; (void) exc; @@ -813,7 +813,7 @@ Reference PackageManagerImpl::addPackage( try { docFolderContent.executeCommand( OUSTR("flush"), Any() ); } - catch (UnsupportedCommandException &) { + catch (const UnsupportedCommandException &) { } } ActivePackages::Data dbData; @@ -861,22 +861,22 @@ Reference PackageManagerImpl::addPackage( } return xPackage; } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (CommandFailedException & exc) { + catch (const CommandFailedException & exc) { logIntern( Any(exc) ); throw; } - catch (CommandAbortedException & exc) { + catch (const CommandAbortedException & exc) { logIntern( Any(exc) ); throw; } - catch (deployment::DeploymentException & exc) { + catch (const deployment::DeploymentException & exc) { logIntern( Any(exc) ); throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); logIntern( exc ); throw deployment::DeploymentException( @@ -964,25 +964,25 @@ void PackageManagerImpl::removePackage( fireModified(); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (lang::IllegalArgumentException &) { + catch (const lang::IllegalArgumentException &) { throw; } - catch (CommandFailedException & exc) { + catch (const CommandFailedException & exc) { logIntern( Any(exc) ); throw; } - catch (CommandAbortedException & exc) { + catch (const CommandAbortedException & exc) { logIntern( Any(exc) ); throw; } - catch (deployment::DeploymentException & exc) { + catch (const deployment::DeploymentException & exc) { logIntern( Any(exc) ); throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); logIntern( exc ); throw deployment::DeploymentException( @@ -1056,7 +1056,7 @@ Reference PackageManagerImpl::getDeployedPackage_( getDeployPath( data ), data.mediaType, false, OUString(), xCmdEnv ); } } - catch (deployment::InvalidRemovedParameterException& e) + catch (const deployment::InvalidRemovedParameterException& e) { xExtension = e.Extension; } @@ -1083,13 +1083,13 @@ PackageManagerImpl::getDeployedPackages_( true /* xxx todo: think of GUI: ignore other platforms than the current one */ ) ); } - catch (lang::IllegalArgumentException & exc) { + catch (const lang::IllegalArgumentException & exc) { // ignore (void) exc; // avoid warnings OSL_FAIL( ::rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); } - catch (deployment::DeploymentException& exc) { + catch (const deployment::DeploymentException& exc) { // ignore (void) exc; // avoid warnings OSL_FAIL( ::rtl::OUStringToOString( @@ -1117,22 +1117,22 @@ Reference PackageManagerImpl::getDeployedPackage( const ::osl::MutexGuard guard( getMutex() ); return getDeployedPackage_( id, fileName, xCmdEnv ); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (CommandFailedException & exc) { + catch (const CommandFailedException & exc) { logIntern( Any(exc) ); throw; } - catch (lang::IllegalArgumentException & exc) { + catch (const lang::IllegalArgumentException & exc) { logIntern( Any(exc) ); throw; } - catch (deployment::DeploymentException & exc) { + catch (const deployment::DeploymentException & exc) { logIntern( Any(exc) ); throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); logIntern( exc ); throw deployment::DeploymentException( @@ -1162,22 +1162,22 @@ PackageManagerImpl::getDeployedPackages( const ::osl::MutexGuard guard( getMutex() ); return getDeployedPackages_( xCmdEnv ); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (CommandFailedException & exc) { + catch (const CommandFailedException & exc) { logIntern( Any(exc) ); throw; } - catch (CommandAbortedException & exc) { + catch (const CommandAbortedException & exc) { logIntern( Any(exc) ); throw; } - catch (deployment::DeploymentException & exc) { + catch (const deployment::DeploymentException & exc) { logIntern( Any(exc) ); throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); logIntern( exc ); throw deployment::DeploymentException( @@ -1226,22 +1226,22 @@ void PackageManagerImpl::reinstallDeployedPackages( //registering is done by the ExtensionManager service. } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (CommandFailedException & exc) { + catch (const CommandFailedException & exc) { logIntern( Any(exc) ); throw; } - catch (CommandAbortedException & exc) { + catch (const CommandAbortedException & exc) { logIntern( Any(exc) ); throw; } - catch (deployment::DeploymentException & exc) { + catch (const deployment::DeploymentException & exc) { logIntern( Any(exc) ); throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); logIntern( exc ); throw deployment::DeploymentException( @@ -1338,7 +1338,7 @@ bool PackageManagerImpl::synchronizeRemovedExtensions( bModified |= true; } } - catch( uno::Exception & ) + catch( const uno::Exception & ) { OSL_ASSERT(0); } @@ -1467,7 +1467,7 @@ bool PackageManagerImpl::synchronizeAddedExtensions( } } } - catch (uno::Exception &) + catch (const uno::Exception &) { OSL_ASSERT(0); } @@ -1533,11 +1533,11 @@ Sequence< Reference > PackageManagerImpl::getExtensionsWit } return ::comphelper::containerToSequence(vec); } - catch (deployment::DeploymentException &) + catch (const deployment::DeploymentException &) { throw; } - catch (RuntimeException&) + catch (const RuntimeException&) { throw; } @@ -1597,15 +1597,15 @@ sal_Int32 PackageManagerImpl::checkPrerequisites( } return 0; } - catch (deployment::DeploymentException& ) { + catch ( const deployment::DeploymentException& ) { throw; - } catch (ucb::CommandFailedException & ) { + } catch ( const ucb::CommandFailedException & ) { throw; - } catch (ucb::CommandAbortedException & ) { + } catch ( const ucb::CommandAbortedException & ) { throw; - } catch (lang::IllegalArgumentException &) { + } catch (const lang::IllegalArgumentException &) { throw; - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; } catch (...) { uno::Any excOccurred = ::cppu::getCaughtException(); diff --git a/desktop/source/deployment/manager/dp_managerfac.cxx b/desktop/source/deployment/manager/dp_managerfac.cxx index 7307dc6ba1bc..2bd2fa74a0b5 100644 --- a/desktop/source/deployment/manager/dp_managerfac.cxx +++ b/desktop/source/deployment/manager/dp_managerfac.cxx @@ -95,7 +95,7 @@ bool singleton_entries( xKey->setStringValue( serviceDecl.getSupportedServiceNames()[0] ); return true; } - catch (registry::InvalidRegistryException & exc) { + catch (const registry::InvalidRegistryException & exc) { (void) exc; // avoid warnings OSL_FAIL( ::rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); diff --git a/desktop/source/deployment/misc/dp_descriptioninfoset.cxx b/desktop/source/deployment/misc/dp_descriptioninfoset.cxx index 17f0b0d58fd2..ec774ad0511d 100644 --- a/desktop/source/deployment/misc/dp_descriptioninfoset.cxx +++ b/desktop/source/deployment/misc/dp_descriptioninfoset.cxx @@ -106,7 +106,7 @@ css::uno::Reference< css::xml::dom::XNode > EmptyNodeList::item(::sal_Int32) OSL_ASSERT(node.is()); try { return node->getNodeValue(); - } catch (css::xml::dom::DOMException & e) { + } catch (const css::xml::dom::DOMException & e) { throw css::uno::RuntimeException( (::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( @@ -209,7 +209,7 @@ ExtensionDescription::ExtensionDescription( { //throws com.sun.star.ucb.InteractiveAugmentedIOException xIn = descContent.openStream(); } - catch (css::uno::Exception& ) + catch ( const css::uno::Exception& ) { if ( ! static_cast(xFilter.get())->exist()) throw NoDescriptionException(); @@ -265,11 +265,11 @@ ExtensionDescription::ExtensionDescription( { throw css::uno::Exception(sDescriptionUri + OUSTR(" contains a root element with an unsupported namespace. "), 0); } - } catch (css::uno::RuntimeException &) { + } catch (const css::uno::RuntimeException &) { throw; - } catch (css::deployment::DeploymentException &) { + } catch (const css::deployment::DeploymentException &) { throw; - } catch (css::uno::Exception & e) { + } catch (const css::uno::Exception & e) { css::uno::Any a(cppu::getCaughtException()); throw css::deployment::DeploymentException( e.Message, Reference< css::uno::XInterface >(), a); @@ -349,8 +349,8 @@ DescriptionInfoset getDescriptionInfoset(OUString const & sExtensionFolderURL) context, sExtensionFolderURL, Reference< css::ucb::XCommandEnvironment >()). getRootElement(); - } catch (NoDescriptionException &) { - } catch (css::deployment::DeploymentException & e) { + } catch (const NoDescriptionException &) { + } catch (const css::deployment::DeploymentException & e) { throw css::uno::RuntimeException( (OUString( RTL_CONSTASCII_USTRINGPARAM( @@ -398,7 +398,7 @@ DescriptionInfoset::~DescriptionInfoset() {} if (m_element.is()) { try { n = m_xpath->selectSingleNode(m_element, expression); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } } @@ -456,7 +456,7 @@ DescriptionInfoset::getDependencies() const { try { return m_xpath->selectNodeList(m_element, ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("desc:dependencies/*"))); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } } @@ -517,7 +517,7 @@ DescriptionInfoset::getUpdateDownloadUrls() const if (m_element.is()) { try { n = m_xpath->selectSingleNode(m_element, expression); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } } @@ -533,7 +533,7 @@ css::uno::Sequence< ::rtl::OUString > DescriptionInfoset::getUrls( if (m_element.is()) { try { ns = m_xpath->selectNodeList(m_element, expression); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } } @@ -557,7 +557,7 @@ css::uno::Sequence< ::rtl::OUString > DescriptionInfoset::getUrls( css::uno::Reference< css::xml::dom::XNode > xPathName; try { xPathName = m_xpath->selectSingleNode(node, exp1); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } OSL_ASSERT(xPathName.is()); @@ -568,7 +568,7 @@ css::uno::Sequence< ::rtl::OUString > DescriptionInfoset::getUrls( css::uno::Reference< css::xml::dom::XNode > xURL; try { xURL = m_xpath->selectSingleNode(node, exp2); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } OSL_ASSERT(xURL.is()); @@ -594,7 +594,7 @@ css::uno::Sequence< ::rtl::OUString > DescriptionInfoset::getUrls( css::uno::Reference< css::xml::dom::XNode > xtext; try { xtext = m_xpath->selectSingleNode(node, exp); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } if (xtext.is()) @@ -620,7 +620,7 @@ DescriptionInfoset::getSimpleLicenseAttributes() const n = m_xpath->selectSingleNode(m_element, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/desc:description/desc:registration/desc:simple-license/@accept-by"))); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } if (n.is()) @@ -669,7 +669,7 @@ DescriptionInfoset::getLocalizedChild( const ::rtl::OUString & sParent) const css::uno::Reference< css::xml::dom::XNode > xParent; try { xParent = m_xpath->selectSingleNode(m_element, sParent); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } css::uno::Reference nodeMatch; @@ -706,7 +706,7 @@ DescriptionInfoset::matchFullLocale(css::uno::Reference< css::xml::dom::XNode > ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("\"]"))); try { return m_xpath->selectSingleNode(xParent, exp1); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore return 0; } @@ -731,7 +731,7 @@ DescriptionInfoset::matchCountryAndLanguage( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("\"]"))); try { nodeMatch = m_xpath->selectSingleNode(xParent, exp1); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } @@ -745,7 +745,7 @@ DescriptionInfoset::matchCountryAndLanguage( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("-\")]"))); try { nodeMatch = m_xpath->selectSingleNode(xParent, exp2); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } } @@ -769,7 +769,7 @@ DescriptionInfoset::matchLanguage( + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("\"]"))); try { nodeMatch = m_xpath->selectSingleNode(xParent, exp1); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } @@ -783,7 +783,7 @@ DescriptionInfoset::matchLanguage( + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("-\")]"))); try { nodeMatch = m_xpath->selectSingleNode(xParent, exp2); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } } @@ -801,7 +801,7 @@ DescriptionInfoset::getChildWithDefaultLocale(css::uno::Reference< css::xml::dom try { nodeDefault = m_xpath->selectSingleNode(xParent, ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("@default-license-id"))); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } if (nodeDefault.is()) @@ -813,7 +813,7 @@ DescriptionInfoset::getChildWithDefaultLocale(css::uno::Reference< css::xml::dom + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("\"]"))); try { return m_xpath->selectSingleNode(xParent, exp1); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } } @@ -822,7 +822,7 @@ DescriptionInfoset::getChildWithDefaultLocale(css::uno::Reference< css::xml::dom const ::rtl::OUString exp2(RTL_CONSTASCII_USTRINGPARAM("*[1]")); try { return m_xpath->selectSingleNode(xParent, exp2); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore return 0; } @@ -844,7 +844,7 @@ DescriptionInfoset::getChildWithDefaultLocale(css::uno::Reference< css::xml::dom css::uno::Reference< css::xml::dom::XNode > xURL; try { xURL = m_xpath->selectSingleNode(node, exp); - } catch (css::xml::xpath::XPathException &) { + } catch (const css::xml::xpath::XPathException &) { // ignore } OSL_ASSERT(xURL.is()); diff --git a/desktop/source/deployment/misc/dp_misc.cxx b/desktop/source/deployment/misc/dp_misc.cxx index f30869074ffa..75686187cb1e 100644 --- a/desktop/source/deployment/misc/dp_misc.cxx +++ b/desktop/source/deployment/misc/dp_misc.cxx @@ -478,7 +478,7 @@ Reference resolveUnoURL( try { return xUnoUrlResolver->resolve( connectString ); } - catch (connection::NoConnectException &) { + catch (const connection::NoConnectException &) { TimeValue tv = { 0 /* secs */, 500000000 /* nanosecs */ }; ::osl::Thread::wait( tv ); } diff --git a/desktop/source/deployment/misc/dp_ucb.cxx b/desktop/source/deployment/misc/dp_ucb.cxx index 4a4e4c471e05..da07a772979c 100644 --- a/desktop/source/deployment/misc/dp_ucb.cxx +++ b/desktop/source/deployment/misc/dp_ucb.cxx @@ -79,10 +79,10 @@ bool create_ucb_content( } return true; } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (Exception &) { + catch (const Exception &) { if (throw_exc) throw; } @@ -154,14 +154,14 @@ bool create_folder( return true; } } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (CommandFailedException &) { + catch (const CommandFailedException &) { // Interaction Handler already handled the error // that has occurred... } - catch (Exception &) { + catch (const Exception &) { if (throw_exc) throw; return false; @@ -187,10 +187,10 @@ bool erase_path( OUString const & url, ucb_content.executeCommand( OUSTR("delete"), Any( true /* delete physically */ ) ); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (Exception &) { + catch (const Exception &) { if (throw_exc) throw; return false; diff --git a/desktop/source/deployment/misc/dp_update.cxx b/desktop/source/deployment/misc/dp_update.cxx index b469238705b5..4995453ebec2 100644 --- a/desktop/source/deployment/misc/dp_update.cxx +++ b/desktop/source/deployment/misc/dp_update.cxx @@ -77,12 +77,12 @@ getUpdateInformation( Reference const & { try { return updateInformation->getUpdateInformation(urls, identifier); - } catch (uno::RuntimeException &) { + } catch (const uno::RuntimeException &) { throw; - } catch (ucb::CommandFailedException & e) { + } catch (const ucb::CommandFailedException & e) { out_error = e.Reason; - } catch (ucb::CommandAbortedException &) { - } catch (uno::Exception & e) { + } catch (const ucb::CommandAbortedException &) { + } catch (const uno::Exception & e) { out_error = uno::makeAny(e); } return diff --git a/desktop/source/deployment/registry/component/dp_compbackenddb.cxx b/desktop/source/deployment/registry/component/dp_compbackenddb.cxx index e8137ba93a5a..2ce1ebc1937f 100644 --- a/desktop/source/deployment/registry/component/dp_compbackenddb.cxx +++ b/desktop/source/deployment/registry/component/dp_compbackenddb.cxx @@ -105,7 +105,7 @@ void ComponentBackendDb::addEntry(::rtl::OUString const & url, Data const & data save(); } } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -142,7 +142,7 @@ ComponentBackendDb::Data ComponentBackendDb::getEntry(::rtl::OUString const & ur } return retData; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( diff --git a/desktop/source/deployment/registry/component/dp_component.cxx b/desktop/source/deployment/registry/component/dp_component.cxx index ba6cf0bdd3f4..2ed0f18df3ce 100644 --- a/desktop/source/deployment/registry/component/dp_component.cxx +++ b/desktop/source/deployment/registry/component/dp_component.cxx @@ -473,10 +473,10 @@ void BackendImpl::disposing() PackageRegistryBackend::disposing(); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); throw lang::WrappedTargetRuntimeException( OUSTR("caught unexpected exception while disposing..."), @@ -1277,7 +1277,7 @@ void BackendImpl::componentLiveInsertion( { try { set->insert(css::uno::Any(*factory++)); - } catch (container::ElementExistException &) { + } catch (const container::ElementExistException &) { OSL_TRACE( "implementation %s already registered", rtl::OUStringToOString(*i, RTL_TEXTENCODING_UTF8).getStr()); @@ -1301,14 +1301,14 @@ void BackendImpl::componentLiveInsertion( name + rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/arguments"))); - } catch (container::NoSuchElementException &) {} + } catch (const container::NoSuchElementException &) {} try { rootContext->insertByName( (name + rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/service"))), css::uno::Any(i->second)); - } catch (container::ElementExistException &) { + } catch (const container::ElementExistException &) { rootContext->replaceByName( (name + rtl::OUString( @@ -1317,7 +1317,7 @@ void BackendImpl::componentLiveInsertion( } try { rootContext->insertByName(name, css::uno::Any()); - } catch (container::ElementExistException &) { + } catch (const container::ElementExistException &) { OSL_TRACE( "singleton %s already registered", rtl::OUStringToOString( @@ -1337,7 +1337,7 @@ void BackendImpl::componentLiveRemoval(ComponentBackendDb::Data const & data) { { try { set->remove(css::uno::Any(*i)); - } catch (css::container::NoSuchElementException &) { + } catch (const css::container::NoSuchElementException &) { // ignore if factory has not been live deployed } } @@ -1362,7 +1362,7 @@ void BackendImpl::componentLiveRemoval(ComponentBackendDb::Data const & data) { name + rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/service"))); rootContext->removeByName(name); - } catch (container::NoSuchElementException &) {} + } catch (const container::NoSuchElementException &) {} } } } diff --git a/desktop/source/deployment/registry/configuration/dp_configuration.cxx b/desktop/source/deployment/registry/configuration/dp_configuration.cxx index 8850efef1ad2..05c27301c4d2 100644 --- a/desktop/source/deployment/registry/configuration/dp_configuration.cxx +++ b/desktop/source/deployment/registry/configuration/dp_configuration.cxx @@ -169,10 +169,10 @@ void BackendImpl::disposing() PackageRegistryBackend::disposing(); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); throw lang::WrappedTargetRuntimeException( OUSTR("caught unexpected exception while disposing..."), @@ -798,7 +798,7 @@ void BackendImpl::PackageImpl::processPackage_( xCmdEnv ).executeCommand( OUSTR("delete"), Any( true /* delete physically */ ) ); } - catch(Exception&) + catch(const Exception&) { OSL_ASSERT(0); } diff --git a/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx b/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx index b0036263e665..6f0c90e554c9 100644 --- a/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx +++ b/desktop/source/deployment/registry/configuration/dp_configurationbackenddb.cxx @@ -92,11 +92,11 @@ void ConfigurationBackendDb::addEntry(::rtl::OUString const & url, Data const & save(); } } - catch (css::deployment::DeploymentException& ) + catch ( const css::deployment::DeploymentException& ) { throw; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -124,11 +124,11 @@ ConfigurationBackendDb::getEntry(::rtl::OUString const & url) } return ::boost::optional(retData); } - catch (css::deployment::DeploymentException& ) + catch ( const css::deployment::DeploymentException& ) { throw; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -159,11 +159,11 @@ ConfigurationBackendDb::getEntry(::rtl::OUString const & url) } return listRet; } - catch (css::deployment::DeploymentException& ) + catch ( const css::deployment::DeploymentException& ) { throw; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( diff --git a/desktop/source/deployment/registry/dp_backend.cxx b/desktop/source/deployment/registry/dp_backend.cxx index c5c3cd2f774d..559b1cce3169 100644 --- a/desktop/source/deployment/registry/dp_backend.cxx +++ b/desktop/source/deployment/registry/dp_backend.cxx @@ -132,10 +132,10 @@ void PackageRegistryBackend::disposing() m_xComponentContext.clear(); WeakComponentImplHelperBase::disposing(); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); throw lang::WrappedTargetRuntimeException( OUSTR("caught unexpected exception while disposing!"), @@ -182,19 +182,19 @@ Reference PackageRegistryBackend::bindPackage( xNewPackage = bindPackage_( url, mediaType, bRemoved, identifier, xCmdEnv ); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (lang::IllegalArgumentException &) { + catch (const lang::IllegalArgumentException &) { throw; } - catch (CommandFailedException &) { + catch (const CommandFailedException &) { throw; } - catch (deployment::DeploymentException &) { + catch (const deployment::DeploymentException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); throw deployment::DeploymentException( OUSTR("Error binding package: ") + url, @@ -304,7 +304,7 @@ void PackageRegistryBackend::deleteUnusedFolders( } } } - catch (ucb::InteractiveAugmentedIOException& e) + catch (const ucb::InteractiveAugmentedIOException& e) { //In case the folder containing all the data folder does not //exist yet, we ignore the exception @@ -622,19 +622,19 @@ beans::Optional< beans::Ambiguous > Package::isRegistered( AbortChannel::get(xAbortChannel), xCmdEnv ); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (CommandFailedException &) { + catch (const CommandFailedException &) { throw; } - catch (CommandAbortedException &) { + catch (const CommandAbortedException &) { throw; } - catch (deployment::DeploymentException &) { + catch (const deployment::DeploymentException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); throw deployment::DeploymentException( OUSTR("unexpected exception occurred!"), @@ -678,21 +678,21 @@ void Package::processPackage_impl( xCmdEnv ); } } - catch (RuntimeException &e) { + catch (const RuntimeException &e) { SAL_WARN( "basic", "unexpected RuntimeException \"" << e.Message << '"'); throw; } - catch (CommandFailedException &) { + catch (const CommandFailedException &) { throw; } - catch (CommandAbortedException &) { + catch (const CommandAbortedException &) { throw; } - catch (deployment::DeploymentException &) { + catch (const deployment::DeploymentException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); throw deployment::DeploymentException( (doRegisterPackage diff --git a/desktop/source/deployment/registry/dp_backenddb.cxx b/desktop/source/deployment/registry/dp_backenddb.cxx index 57b50e751704..ab7e61ccbafd 100644 --- a/desktop/source/deployment/registry/dp_backenddb.cxx +++ b/desktop/source/deployment/registry/dp_backenddb.cxx @@ -165,7 +165,7 @@ void BackendDb::removeElement(::rtl::OUString const & sXPathExpression) OSL_ASSERT(! nextNode.is()); #endif } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -200,7 +200,7 @@ void BackendDb::revokeEntry(::rtl::OUString const & url) save(); } } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -224,7 +224,7 @@ bool BackendDb::activateEntry(::rtl::OUString const & url) } return ret; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -248,7 +248,7 @@ bool BackendDb::hasActiveEntry(::rtl::OUString const & url) return ret; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -277,7 +277,7 @@ Reference BackendDb::getKeyElement( const Reference xpathApi = getXPathAPI(); return xpathApi->selectSingleNode(root, sExpression.makeStringAndClear()); } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -349,7 +349,7 @@ void BackendDb::writeVectorOfPair( secondTextNode, css::uno::UNO_QUERY_THROW)); } } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -395,7 +395,7 @@ BackendDb::readVectorOfPair( } return retVector; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -440,7 +440,7 @@ void BackendDb::writeSimpleList( memberNode->appendChild(textNode); } } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -471,7 +471,7 @@ void BackendDb::writeSimpleElement( doc->createTextNode(value), UNO_QUERY_THROW); dataNode->appendChild(dataValue); } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -523,7 +523,7 @@ Reference BackendDb::writeKeyElement( root->appendChild(keyNode); return keyNode; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -546,7 +546,7 @@ OUString BackendDb::readSimpleElement( return val->getNodeValue(); return OUString(); } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -580,7 +580,7 @@ OUString BackendDb::readSimpleElement( } return retList; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -621,11 +621,11 @@ OUString BackendDb::readSimpleElement( } return listRet; } - catch (css::deployment::DeploymentException& ) + catch ( const css::deployment::DeploymentException& ) { throw; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -673,7 +673,7 @@ void RegisteredDb::addEntry(::rtl::OUString const & url) save(); } } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -699,7 +699,7 @@ bool RegisteredDb::getEntry(::rtl::OUString const & url) return aNode.is(); } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( diff --git a/desktop/source/deployment/registry/dp_registry.cxx b/desktop/source/deployment/registry/dp_registry.cxx index c0a7594447d6..484d557868b1 100644 --- a/desktop/source/deployment/registry/dp_registry.cxx +++ b/desktop/source/deployment/registry/dp_registry.cxx @@ -522,7 +522,7 @@ Reference PackageRegistryImpl::bindPackage( return (*iPos)->bindPackage( url, mediaType, bRemoved, identifier, xCmdEnv ); } - catch (lang::IllegalArgumentException &) { + catch (const lang::IllegalArgumentException &) { } } throw lang::IllegalArgumentException( diff --git a/desktop/source/deployment/registry/help/dp_help.cxx b/desktop/source/deployment/registry/help/dp_help.cxx index 4434262a56d9..9d96328f93be 100644 --- a/desktop/source/deployment/registry/help/dp_help.cxx +++ b/desktop/source/deployment/registry/help/dp_help.cxx @@ -424,7 +424,7 @@ void BackendImpl::implProcessHelp( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.help.HelpIndexer" )), xContext ) , UNO_QUERY ); } - catch (Exception &) + catch (const Exception &) { // i98680: Survive missing lucene } diff --git a/desktop/source/deployment/registry/help/dp_helpbackenddb.cxx b/desktop/source/deployment/registry/help/dp_helpbackenddb.cxx index b7c3d912fbcf..3d202074f6af 100644 --- a/desktop/source/deployment/registry/help/dp_helpbackenddb.cxx +++ b/desktop/source/deployment/registry/help/dp_helpbackenddb.cxx @@ -91,11 +91,11 @@ void HelpBackendDb::addEntry(::rtl::OUString const & url, Data const & data) save(); } } - catch (css::deployment::DeploymentException& ) + catch ( const css::deployment::DeploymentException& ) { throw; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -122,11 +122,11 @@ HelpBackendDb::getEntry(::rtl::OUString const & url) } return ::boost::optional(retData); } - catch (css::deployment::DeploymentException& ) + catch ( const css::deployment::DeploymentException& ) { throw; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( diff --git a/desktop/source/deployment/registry/package/dp_extbackenddb.cxx b/desktop/source/deployment/registry/package/dp_extbackenddb.cxx index 1b32266c1e72..212ba2f7b28b 100644 --- a/desktop/source/deployment/registry/package/dp_extbackenddb.cxx +++ b/desktop/source/deployment/registry/package/dp_extbackenddb.cxx @@ -94,7 +94,7 @@ void ExtensionBackendDb::addEntry(::rtl::OUString const & url, Data const & data save(); } } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -122,7 +122,7 @@ ExtensionBackendDb::Data ExtensionBackendDb::getEntry(::rtl::OUString const & ur } return retData; } - catch(css::uno::Exception &) + catch(const css::uno::Exception &) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( diff --git a/desktop/source/deployment/registry/package/dp_package.cxx b/desktop/source/deployment/registry/package/dp_package.cxx index 09d2f3521463..c9e5163908ac 100644 --- a/desktop/source/deployment/registry/package/dp_package.cxx +++ b/desktop/source/deployment/registry/package/dp_package.cxx @@ -594,7 +594,7 @@ OUString BackendImpl::PackageImpl::getTextFromURL( return OUString( reinterpret_cast( seq.getConstArray()), seq.getLength(), RTL_TEXTENCODING_UTF8); } - catch (css::uno::Exception&) + catch (const css::uno::Exception&) { Any exc( ::cppu::getCaughtException() ); throw css::deployment::DeploymentException( @@ -721,15 +721,15 @@ bool BackendImpl::PackageImpl::checkDependencies( return false; } return true; - } catch (css::ucb::CommandFailedException&) { + } catch (const css::ucb::CommandFailedException&) { throw; - } catch (css::ucb::CommandAbortedException&) { + } catch (const css::ucb::CommandAbortedException&) { throw; - } catch (css::deployment::DeploymentException&) { + } catch (const css::deployment::DeploymentException&) { throw; - } catch (css::uno::RuntimeException&) { + } catch (const css::uno::RuntimeException&) { throw; - } catch (css::uno::Exception&) { + } catch (const css::uno::Exception&) { Any anyExc = cppu::getCaughtException(); throw css::deployment::DeploymentException(OUSTR("Unexpected exception"), 0, anyExc); } @@ -879,7 +879,7 @@ void BackendImpl::PackageImpl::processPackage_( try { xPackage->registerPackage( startup, xSubAbortChannel, xCmdEnv ); } - catch (Exception &) + catch (const Exception &) { //We even try a rollback if the user cancelled the action (CommandAbortedException) //in order to prevent invalid database entries. @@ -913,7 +913,7 @@ void BackendImpl::PackageImpl::processPackage_( bundle[ pos ]->revokePackage( xSubAbortChannel, xCmdEnv ); } - catch (Exception &) + catch (const Exception &) { OSL_FAIL( ::rtl::OUStringToOString( ::comphelper::anyToString( @@ -954,13 +954,13 @@ void BackendImpl::PackageImpl::processPackage_( try { bundle[ pos ]->revokePackage( xSubAbortChannel, xCmdEnv ); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (ucb::CommandAbortedException &) { + catch (const ucb::CommandAbortedException &) { throw; } - catch (Exception &) { + catch (const Exception &) { // CommandFailedException, DeploymentException: Any exc( ::cppu::getCaughtException() ); // try to handle exception, notify: @@ -1004,7 +1004,7 @@ OUString BackendImpl::PackageImpl::getDescription() { sDescription = getTextFromURL( css::uno::Reference< css::ucb::XCommandEnvironment >(), sURL ); } - catch ( css::deployment::DeploymentException& ) + catch ( const css::deployment::DeploymentException& ) { OSL_FAIL( ::rtl::OUStringToOString( ::comphelper::anyToString( ::cppu::getCaughtException() ), RTL_TEXTENCODING_UTF8 ).getStr() ); } @@ -1133,13 +1133,13 @@ void BackendImpl::PackageImpl::exportTo( bundle = getBundle( Reference(), xCmdEnv ); } // xxx todo: think about exception specs: - catch (deployment::DeploymentException &) { + catch (const deployment::DeploymentException &) { OSL_FAIL( ::rtl::OUStringToOString( ::comphelper::anyToString( ::cppu::getCaughtException() ), RTL_TEXTENCODING_UTF8 ).getStr() ); } - catch (lang::IllegalArgumentException & exc) { + catch (const lang::IllegalArgumentException & exc) { (void) exc; OSL_FAIL( ::rtl::OUStringToOString( exc.Message, RTL_TEXTENCODING_UTF8 ).getStr() ); @@ -1225,7 +1225,7 @@ void BackendImpl::PackageImpl::exportTo( try { destFolderContent.executeCommand( OUSTR("flush"), Any() ); } - catch (ucb::UnsupportedCommandException &) { + catch (const ucb::UnsupportedCommandException &) { } } @@ -1290,19 +1290,19 @@ Sequence< Reference > BackendImpl::PackageImpl::getBundle( } } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (ucb::CommandFailedException &) { + catch (const ucb::CommandFailedException &) { throw; } - catch (ucb::CommandAbortedException &) { + catch (const ucb::CommandAbortedException &) { throw; } - catch (deployment::DeploymentException &) { + catch (const deployment::DeploymentException &) { throw; } - catch (Exception &) { + catch (const Exception &) { Any exc( ::cppu::getCaughtException() ); throw deployment::DeploymentException( OUSTR("error scanning bundle: ") + getURL(), @@ -1388,13 +1388,13 @@ Reference BackendImpl::PackageImpl::bindBundleItem( url, mediaType, bRemoved, identifier, xCmdEnv ) ); OSL_ASSERT( xPackage.is() ); } - catch (RuntimeException &) { + catch (const RuntimeException &) { throw; } - catch (ucb::CommandFailedException &) { + catch (const ucb::CommandFailedException &) { // ignore already handled error } - catch (Exception &) { + catch (const Exception &) { const Any exc( ::cppu::getCaughtException() ); if (notifyDetectionError || !exc.isExtractableTo( diff --git a/desktop/source/migration/services/oo3extensionmigration.cxx b/desktop/source/migration/services/oo3extensionmigration.cxx index af609ac8c7e7..1348a1a7c445 100644 --- a/desktop/source/migration/services/oo3extensionmigration.cxx +++ b/desktop/source/migration/services/oo3extensionmigration.cxx @@ -272,10 +272,10 @@ bool OO3ExtensionMigration::scanDescriptionXml( const ::rtl::OUString& sDescript if ( xNode.is() ) aExtIdentifier = xNode->getNodeValue(); } - catch ( xml::xpath::XPathException& ) + catch ( const xml::xpath::XPathException& ) { } - catch ( xml::dom::DOMException& ) + catch ( const xml::dom::DOMException& ) { } } @@ -297,10 +297,10 @@ bool OO3ExtensionMigration::scanDescriptionXml( const ::rtl::OUString& sDescript } } } - catch ( ucb::CommandAbortedException& ) + catch ( const ucb::CommandAbortedException& ) { } - catch ( uno::RuntimeException& ) + catch ( const uno::RuntimeException& ) { } @@ -334,8 +334,8 @@ bool OO3ExtensionMigration::migrateExtension( const ::rtl::OUString& sSourceDir { m_xExtensionManager = deployment::ExtensionManager::get( m_ctx ); } - catch ( ucb::CommandFailedException & ){} - catch ( uno::RuntimeException & ) {} + catch ( const ucb::CommandFailedException & ){} + catch ( const uno::RuntimeException & ) {} } if ( m_xExtensionManager.is() ) @@ -355,13 +355,13 @@ bool OO3ExtensionMigration::migrateExtension( const ::rtl::OUString& sSourceDir if ( xPackage.is() ) return true; } - catch ( ucb::CommandFailedException& ) + catch ( const ucb::CommandFailedException& ) { } - catch ( ucb::CommandAbortedException& ) + catch ( const ucb::CommandAbortedException& ) { } - catch ( lang::IllegalArgumentException& ) + catch ( const lang::IllegalArgumentException& ) { } } diff --git a/desktop/source/offacc/acceptor.cxx b/desktop/source/offacc/acceptor.cxx index 42897a17cc14..caa0564f9f8b 100644 --- a/desktop/source/offacc/acceptor.cxx +++ b/desktop/source/offacc/acceptor.cxx @@ -142,7 +142,7 @@ void SAL_CALL Acceptor::run() rtl::OUString() ,m_aProtocol ,rConnection ,rInstanceProvider ); osl::MutexGuard g(m_aMutex); m_bridges.add(rBridge); - } catch (Exception&) { + } catch (const Exception&) { // connection failed... // something went wrong during connection setup. // just wait for a new connection to accept @@ -241,7 +241,7 @@ Reference< XInterface > Acceptor::impl_getInstance( const Reference< XMultiServi { try { return (XComponent*) new Acceptor( aFactory ); - } catch ( Exception& ) { + } catch ( const Exception& ) { return (XComponent*) NULL; } } diff --git a/desktop/source/pkgchk/unopkg/unopkg_app.cxx b/desktop/source/pkgchk/unopkg/unopkg_app.cxx index 359b136bde1c..9194ae89c91b 100644 --- a/desktop/source/pkgchk/unopkg/unopkg_app.cxx +++ b/desktop/source/pkgchk/unopkg/unopkg_app.cxx @@ -213,7 +213,7 @@ void disposeBridges(Reference ctx) try { comp->dispose(); } - catch (css::lang::DisposedException& ) + catch ( const css::lang::DisposedException& ) { } } @@ -461,7 +461,7 @@ extern "C" DESKTOP_DLLPUBLIC int unopkg_main() cmdPackage, cmdPackage, repository, Reference(), xCmdEnv ); } - catch (lang::IllegalArgumentException &) + catch (const lang::IllegalArgumentException &) { Reference p( findPackage(repository, @@ -535,7 +535,7 @@ extern "C" DESKTOP_DLLPUBLIC int unopkg_main() extension = xExtensionManager->getDeployedExtension( repository, cmdPackages[ pos ], cmdPackages[ pos ], xCmdEnv ); } - catch (lang::IllegalArgumentException &) + catch (const lang::IllegalArgumentException &) { extension = findPackage(repository, xExtensionManager, xCmdEnv, cmdPackages[ pos ] ); @@ -587,7 +587,7 @@ extern "C" DESKTOP_DLLPUBLIC int unopkg_main() extension = xExtensionManager->getDeployedExtension( repository, cmdPackages[ pos ], cmdPackages[ pos ], xCmdEnv ); } - catch (lang::IllegalArgumentException &) + catch (const lang::IllegalArgumentException &) { extension = findPackage( repository, xExtensionManager, xCmdEnv, cmdPackages[ pos ] ); @@ -656,16 +656,16 @@ extern "C" DESKTOP_DLLPUBLIC int unopkg_main() disposeBridges(xLocalComponentContext); return 0; } - catch (ucb::CommandFailedException &e) + catch (const ucb::CommandFailedException &e) { dp_misc::writeConsoleError(e.Message + OUSTR("\n")); bNoOtherErrorMsg = true; } - catch (ucb::CommandAbortedException &) + catch (const ucb::CommandAbortedException &) { dp_misc::writeConsoleError("\n"APP_NAME" aborted!\n"); } - catch (deployment::DeploymentException & exc) + catch (const deployment::DeploymentException & exc) { OUString cause; if (option_verbose) @@ -685,13 +685,13 @@ extern "C" DESKTOP_DLLPUBLIC int unopkg_main() dp_misc::writeConsoleError( OUSTR(" Cause: ") + cause + OUSTR("\n")); } - catch (LockFileException & e) + catch (const LockFileException & e) { if (!subcmd_gui) dp_misc::writeConsoleError(e.Message); bNoOtherErrorMsg = true; } - catch (::com::sun::star::uno::Exception & e ) { + catch (const ::com::sun::star::uno::Exception & e ) { Any exc( ::cppu::getCaughtException() ); dp_misc::writeConsoleError( diff --git a/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx b/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx index 31578f442f45..2b4ba35c5542 100644 --- a/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx +++ b/desktop/source/pkgchk/unopkg/unopkg_cmdenv.cxx @@ -139,7 +139,7 @@ CommandEnvironmentImpl::~CommandEnvironmentImpl() if (xComp.is()) xComp->dispose(); } - catch (RuntimeException & exc) { + catch (const RuntimeException & exc) { (void) exc; OSL_FAIL( ::rtl::OUStringToOString( exc.Message, osl_getThreadTextEncoding() ).getStr() ); diff --git a/desktop/test/deployment/active/active_native.cxx b/desktop/test/deployment/active/active_native.cxx index 3c5f7ecebdd9..9845fd511168 100644 --- a/desktop/test/deployment/active/active_native.cxx +++ b/desktop/test/deployment/active/active_native.cxx @@ -303,7 +303,7 @@ extern "C" sal_Bool SAL_CALL component_writeInfo( "active_native_singleton")))), css::uno::UNO_SET_THROW)-> setStringValue(Dispatch::static_getImplementationName()); - } catch (css::uno::Exception & e) { + } catch (const css::uno::Exception & e) { (void) e; OSL_TRACE( "active_native component_writeInfo exception: %s", -- cgit v1.2.3