[Libreoffice-commits] .: 3 commits - desktop/source scripting/java scripting/workben sfx2/source
Caolán McNamara
caolan at kemper.freedesktop.org
Fri Apr 15 06:09:30 PDT 2011
desktop/source/app/officeipcthread.cxx | 2
scripting/java/build.xml | 1
scripting/workben/build.xml | 1
sfx2/source/appl/opengrf.cxx | 6 +-
sfx2/source/config/evntconf.cxx | 4 -
sfx2/source/dialog/filedlghelper.cxx | 54 +++++++++---------
sfx2/source/dialog/filtergrouping.cxx | 12 ++--
sfx2/source/doc/docfile.cxx | 98 ++++++++++++++++-----------------
sfx2/source/doc/docinsert.cxx | 8 +-
sfx2/source/doc/objuno.cxx | 42 +++++++-------
sfx2/source/menu/virtmenu.cxx | 2
11 files changed, 115 insertions(+), 115 deletions(-)
New commits:
commit 544405d4f6394abda410cf1821be35e30123d8ff
Author: Caolán McNamara <caolanm at redhat.com>
Date: Fri Apr 15 11:49:38 2011 +0100
WaE: remove annoying java warnings
diff --git a/scripting/java/build.xml b/scripting/java/build.xml
index 053c280..e661636 100755
--- a/scripting/java/build.xml
+++ b/scripting/java/build.xml
@@ -29,7 +29,6 @@
<!-- =================== Environmental Properties ======================= -->
<property name="prj" value=".."/>
- <property name="build.compiler" value="classic"/>
<property name="optimize" value="off"/>
<property name="debug" value="on"/>
<property name="jardir" value="${out}/class"/>
diff --git a/scripting/workben/build.xml b/scripting/workben/build.xml
index 10bc6f8..6cd74f7 100755
--- a/scripting/workben/build.xml
+++ b/scripting/workben/build.xml
@@ -30,7 +30,6 @@
<property name="prj" value=".."/>
<property file="${prj}/java/build.env"/>
- <property name="build.compiler" value="classic"/>
<property name="optimize" value="on"/>
<property name="debug" value="on"/>
<property name="installerclasses" value="${out}/class/sframeworkinstall"/>
commit ff31001dec3ab7b37d8102c88441732e66546294
Author: Caolán McNamara <caolanm at redhat.com>
Date: Fri Apr 15 09:57:55 2011 +0100
frim->from
diff --git a/desktop/source/app/officeipcthread.cxx b/desktop/source/app/officeipcthread.cxx
index d89230d..94eecf9 100644
--- a/desktop/source/app/officeipcthread.cxx
+++ b/desktop/source/app/officeipcthread.cxx
@@ -230,7 +230,7 @@ OfficeIPCThread* OfficeIPCThread::pGlobalOfficeIPCThread = 0;
String CreateMD5FromString( const OUString& aMsg )
{
#if (OSL_DEBUG_LEVEL > 1) || defined DBG_UTIL
- fprintf (stderr, "create md5 frim '%s'\n",
+ fprintf (stderr, "create md5 from '%s'\n",
(const sal_Char *)rtl::OUStringToOString (aMsg, RTL_TEXTENCODING_UTF8));
#endif
commit 3481f53886a34a34f30a688fbc81c7e12b4c544e
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Apr 13 21:43:12 2011 +0100
catch by const reference
diff --git a/sfx2/source/appl/opengrf.cxx b/sfx2/source/appl/opengrf.cxx
index f848d42..c24d05d 100644
--- a/sfx2/source/appl/opengrf.cxx
+++ b/sfx2/source/appl/opengrf.cxx
@@ -211,7 +211,7 @@ void SvxOpenGraphicDialog::EnableLink( sal_Bool state )
{
mpImpl->xCtrlAcc->enableControl( ExtendedFilePickerElementIds::CHECKBOX_LINK, state );
}
- catch(IllegalArgumentException)
+ catch(const IllegalArgumentException&)
{
#ifdef DBG_UTIL
OSL_FAIL( "Cannot enable \"link\" checkbox" );
@@ -230,7 +230,7 @@ void SvxOpenGraphicDialog::AsLink(sal_Bool bState)
Any aAny; aAny <<= bState;
mpImpl->xCtrlAcc->setValue( ExtendedFilePickerElementIds::CHECKBOX_LINK, 0, aAny );
}
- catch(IllegalArgumentException)
+ catch(const IllegalArgumentException&)
{
#ifdef DBG_UTIL
OSL_FAIL( "Cannot check \"link\" checkbox" );
@@ -251,7 +251,7 @@ sal_Bool SvxOpenGraphicDialog::IsAsLink() const
return aVal.hasValue() ? *(sal_Bool*) aVal.getValue() : sal_False;
}
}
- catch(IllegalArgumentException)
+ catch(const IllegalArgumentException&)
{
#ifdef DBG_UTIL
OSL_FAIL( "Cannot access \"link\" checkbox" );
diff --git a/sfx2/source/config/evntconf.cxx b/sfx2/source/config/evntconf.cxx
index 5adbc48..b4b4b88 100644
--- a/sfx2/source/config/evntconf.cxx
+++ b/sfx2/source/config/evntconf.cxx
@@ -256,9 +256,9 @@ void PropagateEvent_Impl( SfxObjectShell *pDoc, rtl::OUString aEventName, const
{
xEvents->replaceByName( aEventName, aEventData );
}
- catch( ::com::sun::star::lang::IllegalArgumentException )
+ catch( const ::com::sun::star::lang::IllegalArgumentException& )
{ DBG_ERRORFILE( "PropagateEvents_Impl: caught IllegalArgumentException" ); }
- catch( ::com::sun::star::container::NoSuchElementException )
+ catch( const ::com::sun::star::container::NoSuchElementException& )
{ DBG_ERRORFILE( "PropagateEvents_Impl: caught NoSuchElementException" ); }
}
else {
diff --git a/sfx2/source/dialog/filedlghelper.cxx b/sfx2/source/dialog/filedlghelper.cxx
index 610bbf2..5db2343 100644
--- a/sfx2/source/dialog/filedlghelper.cxx
+++ b/sfx2/source/dialog/filedlghelper.cxx
@@ -438,7 +438,7 @@ sal_Bool FileDialogHelper_Impl::CheckFilterOptionsCapability( const SfxFilter* _
}
}
}
- catch( Exception& )
+ catch( const Exception& )
{
}
}
@@ -618,7 +618,7 @@ void FileDialogHelper_Impl::updatePreviewState( sal_Bool _bUpdatePreviewWindow )
TimeOutHdl_Impl( NULL );
}
}
- catch( Exception )
+ catch( const Exception& )
{
DBG_ERRORFILE( "FileDialogHelper_Impl::updatePreviewState: caught an exception!" );
}
@@ -657,7 +657,7 @@ void FileDialogHelper_Impl::updateVersions()
for ( sal_Int32 i=0; i<xVersions.getLength(); i++ )
aEntries[ i + 1 ] = xVersions[i].Identifier;
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
}
}
@@ -671,7 +671,7 @@ void FileDialogHelper_Impl::updateVersions()
xDlg->setValue( ExtendedFilePickerElementIds::LISTBOX_VERSION,
ControlActions::DELETE_ITEMS, aValue );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
sal_Int32 nCount = aEntries.getLength();
@@ -688,7 +688,7 @@ void FileDialogHelper_Impl::updateVersions()
xDlg->setValue( ExtendedFilePickerElementIds::LISTBOX_VERSION,
ControlActions::SET_SELECT_ITEM, aPos );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
}
@@ -760,7 +760,7 @@ IMPL_LINK( FileDialogHelper_Impl, TimeOutHdl_Impl, Timer*, EMPTYARG )
// clear the preview window
xFilePicker->setImage( FilePreviewImageFormats::BITMAP, aAny );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
}
@@ -1108,7 +1108,7 @@ FileDialogHelper_Impl::FileDialogHelper_Impl(
xExtDlg->setLabel( CommonFilePickerElementIds::PUSHBUTTON_OK,
OUString( String( SfxResId( STR_SFX_EXPLORERFILE_BUTTONINSERT ) ) ) );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
}
@@ -1160,7 +1160,7 @@ void SAL_CALL PickerThread_Impl::run()
sal_Int16 n = mxPicker->execute();
SetReturnValue( n );
}
- catch( RuntimeException& )
+ catch( const RuntimeException& )
{
SetReturnValue( ExecutableDialogResults::CANCEL );
DBG_ERRORFILE( "RuntimeException caught" );
@@ -1496,7 +1496,7 @@ ErrCode FileDialogHelper_Impl::execute( SvStringsDtor*& rpURLList,
if ( aValue >>= bSelection )
rpSet->Put( SfxBoolItem( SID_SELECTION, bSelection ) );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
OSL_FAIL( "FileDialogHelper_Impl::execute: caught an IllegalArgumentException!" );
}
@@ -1517,7 +1517,7 @@ ErrCode FileDialogHelper_Impl::execute( SvStringsDtor*& rpURLList,
if ( ( aValue >>= bReadOnly ) && bReadOnly )
rpSet->Put( SfxBoolItem( SID_DOC_READONLY, bReadOnly ) );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
OSL_FAIL( "FileDialogHelper_Impl::execute: caught an IllegalArgumentException!" );
}
@@ -1534,7 +1534,7 @@ ErrCode FileDialogHelper_Impl::execute( SvStringsDtor*& rpURLList,
// open a special version; 0 == current version
rpSet->Put( SfxInt16Item( SID_VERSION, (short)nVersion ) );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
// set the filter
@@ -1622,7 +1622,7 @@ ErrCode FileDialogHelper_Impl::execute( SvStringsDtor*& rpURLList,
}
}
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
SaveLastUsedFilter();
@@ -1752,7 +1752,7 @@ void FileDialogHelper_Impl::setFilter( const OUString& rFilter )
{
xFltMgr->setCurrentFilter( maCurFilter );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
}
@@ -1812,7 +1812,7 @@ void FileDialogHelper_Impl::addFilters( sal_Int64 nFlags,
{
xResult = xFilterCont->createSubSetEnumerationByQuery(sQuery.makeStringAndClear());
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
DBG_ERRORFILE( "Could not get filters from the configuration!" );
}
@@ -1852,7 +1852,7 @@ void FileDialogHelper_Impl::addFilter( const OUString& rFilterName,
if ( !maSelectFilter.getLength() )
maSelectFilter = rFilterName;
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
#ifdef DBG_UTIL
ByteString aMsg( "Could not append Filter" );
@@ -1909,7 +1909,7 @@ void FileDialogHelper_Impl::addGraphicFilter()
xFltMgr->appendFilter( aAllFilterName, aExtensions );
maSelectFilter = aAllFilterName;
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
DBG_ERRORFILE( "Could not append Filter" );
}
@@ -1938,7 +1938,7 @@ void FileDialogHelper_Impl::addGraphicFilter()
{
xFltMgr->appendFilter( aName, aExt );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
DBG_ERRORFILE( "Could not append Filter" );
}
@@ -1981,7 +1981,7 @@ void FileDialogHelper_Impl::saveConfig()
aDlgOpt.SetUserItem( USERITEM_NAME, makeAny( OUString( aUserData ) ) );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
else
{
@@ -2007,7 +2007,7 @@ void FileDialogHelper_Impl::saveConfig()
aUserData.SetToken( 0, ' ', String::CreateFromInt32( (sal_Int32) bAutoExt ) );
bWriteConfig = sal_True;
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
if ( ! mbIsSaveDlg )
@@ -2033,7 +2033,7 @@ void FileDialogHelper_Impl::saveConfig()
aUserData.SetToken( 2, ' ', String::CreateFromInt32( (sal_Int32) bSelection ) );
bWriteConfig = sal_True;
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
if ( bWriteConfig )
@@ -2068,7 +2068,7 @@ namespace
::ucbhelper::Content aContent( sPathCheck, uno::Reference< ucb::XCommandEnvironment >() );
bValid = aContent.isFolder();
}
- catch( Exception& ) {}
+ catch( const Exception& ) {}
}
if ( !bValid )
@@ -2125,7 +2125,7 @@ void FileDialogHelper_Impl::loadConfig()
// set the member so we know that we have to show the preview
mbShowPreview = bShowPreview;
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
if ( !maPath.getLength() )
@@ -2158,7 +2158,7 @@ void FileDialogHelper_Impl::loadConfig()
{
xDlg->setValue( ExtendedFilePickerElementIds::CHECKBOX_AUTOEXTENSION, 0, aValue );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
if( mbHasSelectionBox )
@@ -2169,7 +2169,7 @@ void FileDialogHelper_Impl::loadConfig()
{
xDlg->setValue( ExtendedFilePickerElementIds::CHECKBOX_SELECTION, 0, aValue );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
if ( !maPath.getLength() )
@@ -2188,7 +2188,7 @@ void FileDialogHelper_Impl::setDefaultValues()
{
xFltMgr->setCurrentFilter( maSelectFilter );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{}
}
@@ -2596,7 +2596,7 @@ static int impl_isFolder( const OUString& rPath )
xHandler.set( xFactory->createInstance( DEFINE_CONST_OUSTRING( "com.sun.star.task.InteractionHandler" ) ),
uno::UNO_QUERY_THROW );
}
- catch ( Exception const & )
+ catch ( const Exception & )
{
}
@@ -2611,7 +2611,7 @@ static int impl_isFolder( const OUString& rPath )
return 0;
}
- catch ( Exception const & )
+ catch ( const Exception & )
{
}
diff --git a/sfx2/source/dialog/filtergrouping.cxx b/sfx2/source/dialog/filtergrouping.cxx
index f3723ca..d1605d4 100644
--- a/sfx2/source/dialog/filtergrouping.cxx
+++ b/sfx2/source/dialog/filtergrouping.cxx
@@ -972,7 +972,7 @@ namespace sfx2
if ( !_rFirstNonEmpty.getLength() )
_rFirstNonEmpty = sUIName;
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
#ifdef DBG_UTIL
ByteString aMsg( "Could not append DefaultFilter" );
@@ -996,7 +996,7 @@ namespace sfx2
if ( !_rFirstNonEmpty.getLength() )
_rFirstNonEmpty = sUIName;
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
#ifdef DBG_UTIL
ByteString aMsg( "Could not append Filter" );
@@ -1108,7 +1108,7 @@ namespace sfx2
{
xFilterGroupManager->appendFilterGroup( ::rtl::OUString(), aFilters );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
}
}
@@ -1128,7 +1128,7 @@ namespace sfx2
{
xFilterGroupManager->appendFilterGroup( ::rtl::OUString(), aFilters );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
}
}
@@ -1150,7 +1150,7 @@ namespace sfx2
_rFirstNonEmpty = sUIName;
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
#ifdef DBG_UTIL
ByteString aMsg( "Could not append Filter" );
@@ -1172,7 +1172,7 @@ namespace sfx2
_rFirstNonEmpty = sUIName;
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
#ifdef DBG_UTIL
ByteString aMsg( "Could not append Filter" );
diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index 6c09670..35b4477 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -416,7 +416,7 @@ void SfxMedium::AddLog( const ::rtl::OUString& aMessage )
if ( aContext.is() )
pImp->m_xLogRing.set( aContext.getSingleton( "com.sun.star.logging.DocumentIOLogRing" ), UNO_QUERY_THROW );
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{}
}
@@ -475,7 +475,7 @@ void SfxMedium::CheckFileDate( const util::DateTime& aInitDate )
SetError( ERRCODE_ABORT, ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ) );
}
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{}
}
}
@@ -500,7 +500,7 @@ util::DateTime SfxMedium::GetInitFileDate( sal_Bool bIgnoreOldValue )
aContent.getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "DateModified" )) ) >>= pImp->m_aDateTime;
pImp->m_bGotDateTime = sal_True;
}
- catch ( ::com::sun::star::uno::Exception& )
+ catch ( const ::com::sun::star::uno::Exception& )
{
}
}
@@ -526,7 +526,7 @@ Reference < XContent > SfxMedium::GetContent() const
{
pImp->aContent = ::ucbhelper::Content( xContent, xEnv );
}
- catch ( Exception& )
+ catch ( const Exception& )
{
}
}
@@ -560,7 +560,7 @@ Reference < XContent > SfxMedium::GetContent() const
Any aAny = pImp->aContent.getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("BaseURI" )) );
aAny >>= aBaseURL;
}
- catch ( ::com::sun::star::uno::Exception& )
+ catch ( const ::com::sun::star::uno::Exception& )
{
}
@@ -890,7 +890,7 @@ void SfxMedium::SetEncryptionDataToStorage_Impl()
{
::comphelper::OStorageHelper::SetCommonStorageEncryptionData( pImp->xStorage, aEncryptionData );
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
OSL_FAIL( "It must be possible to set a common password for the storage" );
// TODO/LATER: set the error code in case of problem
@@ -1067,7 +1067,7 @@ sal_Bool SfxMedium::LockOrigFileOnDemand( sal_Bool bLoading, sal_Bool bNoUI )
::ucbhelper::Content aContent( GetURLObject().GetMainURL( INetURLObject::NO_DECODE ), xDummyEnv );
aContent.getPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "IsReadOnly" ) ) ) >>= bContentReadonly;
}
- catch( uno::Exception )
+ catch( const uno::Exception& )
{}
#if EXTRA_ACL_CHECK
@@ -1120,7 +1120,7 @@ sal_Bool SfxMedium::LockOrigFileOnDemand( sal_Bool bLoading, sal_Bool bNoUI )
{
bResult = aLockFile.CreateOwnLockFile();
}
- catch ( ucb::InteractiveIOException& e )
+ catch ( const ucb::InteractiveIOException& e )
{
// exception means that the lock file can not be successfuly accessed
// in this case it should be ignored if system file locking is anyway active
@@ -1152,7 +1152,7 @@ sal_Bool SfxMedium::LockOrigFileOnDemand( sal_Bool bLoading, sal_Bool bNoUI )
}
}
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{
// exception means that the lock file can not be successfuly accessed
// in this case it should be ignored if system file locking is anyway active
@@ -1183,7 +1183,9 @@ sal_Bool SfxMedium::LockOrigFileOnDemand( sal_Bool bLoading, sal_Bool bNoUI )
// impossibility to get data is no real problem
aData = aLockFile.GetLockData();
}
- catch( uno::Exception ) {}
+ catch( const uno::Exception& )
+ {
+ }
sal_Bool bOwnLock = sal_False;
@@ -1216,7 +1218,7 @@ sal_Bool SfxMedium::LockOrigFileOnDemand( sal_Bool bLoading, sal_Bool bNoUI )
bHandleSysLocked = sal_False;
}
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
}
} while( !bResult && bUIStatus == LOCK_UI_TRY );
@@ -1247,7 +1249,7 @@ sal_Bool SfxMedium::LockOrigFileOnDemand( sal_Bool bLoading, sal_Bool bNoUI )
if ( bResult && DocNeedsFileDateCheck() )
GetInitFileDate( sal_True );
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
OSL_FAIL( "Unexpected problem by locking, high probability, that the content could not be created" );
}
@@ -1328,7 +1330,7 @@ uno::Reference < embed::XStorage > SfxMedium::GetStorage( sal_Bool bCreateTempIf
::comphelper::OStorageHelper::GetStorageFactory()->createInstanceWithArguments( aArgs ),
uno::UNO_QUERY );
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
// impossibility to create the storage is no error
}
@@ -1441,7 +1443,7 @@ uno::Reference< embed::XStorage > SfxMedium::GetZipStorageToSign_Impl( sal_Bool
pImp->m_xZipStorage = ::comphelper::OStorageHelper::GetStorageOfFormatFromInputStream( ZIP_STORAGE_FORMAT_STRING, pImp->xInputStream );
}
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
OSL_FAIL( "No possibility to get readonly version of storage from medium!\n" );
}
@@ -1460,7 +1462,7 @@ void SfxMedium::CloseZipStorage_Impl()
{
try {
pImp->m_xZipStorage->dispose();
- } catch( uno::Exception& )
+ } catch( const uno::Exception& )
{}
pImp->m_xZipStorage = uno::Reference< embed::XStorage >();
@@ -1478,7 +1480,7 @@ void SfxMedium::CloseStorage()
{
try {
xComp->dispose();
- } catch( uno::Exception& )
+ } catch( const uno::Exception& )
{
OSL_FAIL( "Medium's storage is already disposed!\n" );
}
@@ -1536,7 +1538,7 @@ sal_Bool SfxMedium::UseBackupToRestore_Impl( ::ucbhelper::Content& aOriginalCont
aOriginalContent.writeStream( aOrigInput, sal_True );
return sal_True;
}
- catch( Exception& )
+ catch( const Exception& )
{
// in case of failure here the backup file should not be removed
// TODO/LATER: a message should be used to let user know about the backup
@@ -1568,7 +1570,7 @@ sal_Bool SfxMedium::StorageCommit_Impl()
CloseZipStorage_Impl();
bResult = sal_True;
}
- catch ( embed::UseBackupException& aBackupExc )
+ catch ( const embed::UseBackupException& aBackupExc )
{
// since the temporary file is created always now, the scenario is close to be impossible
if ( !pImp->pTempFile )
@@ -1595,7 +1597,7 @@ sal_Bool SfxMedium::StorageCommit_Impl()
SetError( ERRCODE_IO_GENERAL, ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ) );
}
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{
//TODO/LATER: improve error handling
SetError( ERRCODE_IO_GENERAL, ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( OSL_LOG_PREFIX ) ) );
@@ -1621,11 +1623,11 @@ sal_Bool SfxMedium::TransactedTransferForFS_Impl( const INetURLObject& aSource,
{
aOriginalContent = ::ucbhelper::Content( aDest.GetMainURL( INetURLObject::NO_DECODE ), xComEnv );
}
- catch ( ::com::sun::star::ucb::CommandAbortedException& )
+ catch ( const ::com::sun::star::ucb::CommandAbortedException& )
{
eError = ERRCODE_ABORT;
}
- catch ( ::com::sun::star::ucb::CommandFailedException& )
+ catch ( const ::com::sun::star::ucb::CommandFailedException& )
{
eError = ERRCODE_ABORT;
}
@@ -1689,15 +1691,15 @@ sal_Bool SfxMedium::TransactedTransferForFS_Impl( const INetURLObject& aSource,
bResult = sal_True;
}
}
- catch ( ::com::sun::star::ucb::CommandAbortedException& )
+ catch ( const ::com::sun::star::ucb::CommandAbortedException& )
{
eError = ERRCODE_ABORT;
}
- catch ( ::com::sun::star::ucb::CommandFailedException& )
+ catch ( const ::com::sun::star::ucb::CommandFailedException& )
{
eError = ERRCODE_ABORT;
}
- catch ( ::com::sun::star::ucb::InteractiveIOException& r )
+ catch ( const ::com::sun::star::ucb::InteractiveIOException& r )
{
if ( r.Code == IOErrorCode_ACCESS_DENIED )
eError = ERRCODE_IO_ACCESSDENIED;
@@ -1708,7 +1710,7 @@ sal_Bool SfxMedium::TransactedTransferForFS_Impl( const INetURLObject& aSource,
else
eError = ERRCODE_IO_GENERAL;
}
- catch ( ::com::sun::star::uno::Exception& )
+ catch ( const ::com::sun::star::uno::Exception& )
{
eError = ERRCODE_IO_GENERAL;
}
@@ -1793,7 +1795,7 @@ sal_Bool SfxMedium::TryDirectTransfer( const ::rtl::OUString& aURL, SfxItemSet&
return sal_True;
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{}
}
}
@@ -1868,7 +1870,7 @@ void SfxMedium::Transfer_Impl()
pImp->pTempFile = NULL;
}
}
- catch( Exception& )
+ catch( const Exception& )
{}
}
}
@@ -1916,7 +1918,7 @@ void SfxMedium::Transfer_Impl()
xTrans->commit();
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{
//TODO/MBA: error handling
}
@@ -2000,15 +2002,15 @@ void SfxMedium::Transfer_Impl()
if (!aTransferContent.transferContent( aSourceContent, ::ucbhelper::InsertOperation_COPY, aFileName, nNameClash ))
eError = ERRCODE_IO_GENERAL;
}
- catch ( ::com::sun::star::ucb::CommandAbortedException& )
+ catch ( const ::com::sun::star::ucb::CommandAbortedException& )
{
eError = ERRCODE_ABORT;
}
- catch ( ::com::sun::star::ucb::CommandFailedException& )
+ catch ( const ::com::sun::star::ucb::CommandFailedException& )
{
eError = ERRCODE_ABORT;
}
- catch ( ::com::sun::star::ucb::InteractiveIOException& r )
+ catch ( const ::com::sun::star::ucb::InteractiveIOException& r )
{
if ( r.Code == IOErrorCode_ACCESS_DENIED )
eError = ERRCODE_IO_ACCESSDENIED;
@@ -2019,7 +2021,7 @@ void SfxMedium::Transfer_Impl()
else
eError = ERRCODE_IO_GENERAL;
}
- catch ( ::com::sun::star::uno::Exception& )
+ catch ( const ::com::sun::star::uno::Exception& )
{
eError = ERRCODE_IO_GENERAL;
}
@@ -2070,7 +2072,7 @@ void SfxMedium::DoInternalBackup_Impl( const ::ucbhelper::Content& aOriginalCont
pImp->m_bRemoveBackup = sal_True;
}
}
- catch( Exception& )
+ catch( const Exception& )
{}
}
@@ -2157,7 +2159,7 @@ void SfxMedium::DoBackup_Impl()
pImp->m_bRemoveBackup = sal_False;
}
}
- catch ( ::com::sun::star::uno::Exception& )
+ catch ( const ::com::sun::star::uno::Exception& )
{
}
}
@@ -2682,7 +2684,7 @@ void SfxMedium::UnlockFile( sal_Bool bReleaseLockStream )
if ( xOutStream.is() )
xOutStream->closeOutput();
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{}
}
@@ -2698,7 +2700,7 @@ void SfxMedium::UnlockFile( sal_Bool bReleaseLockStream )
// TODO/LATER: A warning could be shown in case the file is not the own one
aLockFile.RemoveFile();
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{}
}
}
@@ -2731,7 +2733,7 @@ void SfxMedium::CloseAndReleaseStreams_Impl()
if ( xOutToClose.is() )
xOutToClose->closeOutput();
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{
}
}
@@ -3127,7 +3129,7 @@ SvKeyValueIterator* SfxMedium::GetHeaderAttributes_Impl()
pImp->xAttributes->Append( SvKeyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("content-type")), aContentType ) );
}
- catch ( ::com::sun::star::uno::Exception& )
+ catch ( const ::com::sun::star::uno::Exception& )
{
}
}
@@ -3168,7 +3170,7 @@ const uno::Sequence < util::RevisionTag >& SfxMedium::GetVersionList( bool _bNoR
{
pImp->aVersions = xReader->load( GetStorage() );
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{
}
}
@@ -3190,7 +3192,7 @@ uno::Sequence < util::RevisionTag > SfxMedium::GetVersionList( const uno::Refere
{
return xReader->load( xStorage );
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{
}
}
@@ -3279,7 +3281,7 @@ sal_Bool SfxMedium::SaveVersionList_Impl( sal_Bool /*bUseXML*/ )
xWriter->store( GetStorage(), pImp->aVersions );
return sal_True;
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{
}
}
@@ -3392,7 +3394,7 @@ void SfxMedium::CreateTempFile( sal_Bool bReplace )
}
}
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{}
if ( bTransferSuccess )
@@ -3492,7 +3494,7 @@ void SfxMedium::CreateTempFileNoCopy()
pImp->aCharset = pCharset->m_sValue;
}
}
- catch ( ::com::sun::star::uno::Exception& )
+ catch ( const ::com::sun::star::uno::Exception& )
{
}
}
@@ -3595,7 +3597,7 @@ sal_Bool SfxMedium::SignContents_Impl( sal_Bool bScriptingContent, const ::rtl::
}
}
}
- catch ( uno::Exception& )
+ catch ( const uno::Exception& )
{
OSL_FAIL( "Couldn't use signing functionality!\n" );
}
@@ -3611,7 +3613,7 @@ sal_Bool SfxMedium::SignContents_Impl( sal_Bool bScriptingContent, const ::rtl::
else
xSigner->showDocumentContentSignatures( GetZipStorageToSign_Impl(), uno::Reference< io::XInputStream >() );
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
OSL_FAIL( "Couldn't use signing functionality!\n" );
}
@@ -3679,7 +3681,7 @@ sal_Bool SfxMedium::IsOpen() const
aResult = aNewTempFileURL;
}
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{}
}
}
@@ -3766,7 +3768,7 @@ sal_Bool SfxMedium::CallApproveHandler( const uno::Reference< task::XInteraction
pImp->xStorage = xStorage;
aResult = aNewURL;
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{}
}
@@ -3828,7 +3830,7 @@ sal_Bool SfxMedium::SwitchDocumentToFile( ::rtl::OUString aURL )
pImp->xStorage = xStorage;
bResult = sal_True;
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{}
}
diff --git a/sfx2/source/doc/docinsert.cxx b/sfx2/source/doc/docinsert.cxx
index 9b1ebfe..6765c22 100644
--- a/sfx2/source/doc/docinsert.cxx
+++ b/sfx2/source/doc/docinsert.cxx
@@ -235,7 +235,7 @@ IMPL_LINK( DocumentInserter, DialogClosedHdl, sfx2::FileDialogHelper*, EMPTYARG
}
}
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
if ( SFXWB_EXPORT == ( m_nDlgFlags & SFXWB_EXPORT ) )
@@ -247,7 +247,7 @@ IMPL_LINK( DocumentInserter, DialogClosedHdl, sfx2::FileDialogHelper*, EMPTYARG
if ( aValue >>= bSelection )
m_pItemSet->Put( SfxBoolItem( SID_SELECTION, bSelection ) );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
OSL_FAIL( "FileDialogHelper_Impl::execute: caught an IllegalArgumentException!" );
}
@@ -268,7 +268,7 @@ IMPL_LINK( DocumentInserter, DialogClosedHdl, sfx2::FileDialogHelper*, EMPTYARG
if ( ( aValue >>= bReadOnly ) && bReadOnly )
m_pItemSet->Put( SfxBoolItem( SID_DOC_READONLY, bReadOnly ) );
}
- catch( IllegalArgumentException )
+ catch( const IllegalArgumentException& )
{
OSL_FAIL( "FileDialogHelper_Impl::execute: caught an IllegalArgumentException!" );
}
@@ -286,7 +286,7 @@ IMPL_LINK( DocumentInserter, DialogClosedHdl, sfx2::FileDialogHelper*, EMPTYARG
// open a special version; 0 == current version
m_pItemSet->Put( SfxInt16Item( SID_VERSION, (short)nVersion ) );
}
- catch( IllegalArgumentException ){}
+ catch( const IllegalArgumentException& ){}
}
}
diff --git a/sfx2/source/doc/objuno.cxx b/sfx2/source/doc/objuno.cxx
index 0e105f3..290631c 100644
--- a/sfx2/source/doc/objuno.cxx
+++ b/sfx2/source/doc/objuno.cxx
@@ -205,7 +205,7 @@ void Copy( const uno::Reference < document::XStandaloneDocumentInfo >& rSource,
// it is possible that the propertysets from XML and binary files differ; we shouldn't break then
xTarget->setPropertyValue( pProps[i].Name, aValue );
}
- catch ( uno::Exception& ) {}
+ catch ( const uno::Exception& ) {}
}
sal_Int16 nCount = rSource->getUserFieldCount();
@@ -218,7 +218,7 @@ void Copy( const uno::Reference < document::XStandaloneDocumentInfo >& rSource,
rTarget->setUserFieldValue( nInd, aPropVal );
}
}
- catch ( uno::Exception& ) {}
+ catch ( const uno::Exception& ) {}
}
class MixedPropertySetInfo : public ::cppu::WeakImplHelper1< ::com::sun::star::beans::XPropertySetInfo >
@@ -401,9 +401,9 @@ void SfxDocumentInfoObject_Impl::Reset(uno::Reference<document::XDocumentPropert
xPropContainer->addProperty(name,
beans::PropertyAttribute::REMOVEABLE,
uno::makeAny(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(""))));
- } catch (uno::RuntimeException) {
+ } catch (const uno::RuntimeException&) {
throw;
- } catch (uno::Exception) {
+ } catch (const uno::Exception&) {
// ignore
}
}
@@ -1082,9 +1082,9 @@ sal_Int16 SAL_CALL SfxDocumentInfoObject::getUserFieldCount() throw( ::com::sun
try {
xPropSet->getPropertyValue(name) >>= val;
return val;
- } catch (uno::RuntimeException &) {
+ } catch (const uno::RuntimeException &) {
throw;
- } catch (uno::Exception &) {
+ } catch (const uno::Exception &) {
return ::rtl::OUString(); // ignore
}
} else
@@ -1115,26 +1115,26 @@ void SAL_CALL SfxDocumentInfoObject::setUserFieldName(sal_Int16 nIndex, const :
xPropContainer->addProperty(aName,
beans::PropertyAttribute::REMOVEABLE, value);
_pImp->m_UserDefined[nIndex] = aName;
- } catch (beans::UnknownPropertyException) {
+ } catch (const beans::UnknownPropertyException&) {
try {
xPropContainer->addProperty(aName,
beans::PropertyAttribute::REMOVEABLE,
uno::makeAny(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(""))));
_pImp->m_UserDefined[nIndex] = aName;
- } catch (beans::PropertyExistException) {
+ } catch (const beans::PropertyExistException&) {
_pImp->m_UserDefined[nIndex] = aName;
// ignore
}
- } catch (beans::PropertyExistException) {
+ } catch (const beans::PropertyExistException&) {
try {
xPropContainer->addProperty(name,
beans::PropertyAttribute::REMOVEABLE, value);
- } catch (beans::PropertyExistException) {
+ } catch (const beans::PropertyExistException&) {
// bugger...
}
- } catch (uno::RuntimeException &) {
+ } catch (const uno::RuntimeException &) {
throw;
- } catch (uno::Exception &) {
+ } catch (const uno::Exception &) {
// ignore everything else; xPropSet _may_ be corrupted
}
}
@@ -1162,19 +1162,19 @@ void SAL_CALL SfxDocumentInfoObject::setUserFieldValue( sal_Int16 nIndex, const
if (value != aAny) {
xPropSet->setPropertyValue(name, aAny);
}
- } catch (beans::UnknownPropertyException) {
+ } catch (const beans::UnknownPropertyException&) {
try {
// someone removed it, add it back again
xPropContainer->addProperty(name,
beans::PropertyAttribute::REMOVEABLE, aAny);
- } catch (uno::RuntimeException &) {
+ } catch (const uno::RuntimeException &) {
throw;
- } catch (uno::Exception &) {
+ } catch (const uno::Exception &) {
// ignore everything else
}
- } catch (uno::RuntimeException &) {
+ } catch (const uno::RuntimeException &) {
throw;
- } catch (uno::Exception &) {
+ } catch (const uno::Exception &) {
// ignore everything else
}
}
@@ -1293,7 +1293,7 @@ void SAL_CALL SfxStandaloneDocumentInfoObject::loadFromURL(const ::rtl::OUStrin
_pImp->Reset(_pImp->m_xDocProps);
bOK = sal_True;
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
}
}
@@ -1333,15 +1333,15 @@ void SAL_CALL SfxStandaloneDocumentInfoObject::storeIntoURL(const ::rtl::OUStri
_pImp->m_xDocProps->storeToStorage(xStorage, medium);
bOK = sal_True;
}
- catch( io::IOException & )
+ catch( const io::IOException & )
{
throw;
}
- catch( uno::RuntimeException& )
+ catch( const uno::RuntimeException& )
{
throw;
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
}
}
diff --git a/sfx2/source/menu/virtmenu.cxx b/sfx2/source/menu/virtmenu.cxx
index 1fdabf9..b9fd414 100644
--- a/sfx2/source/menu/virtmenu.cxx
+++ b/sfx2/source/menu/virtmenu.cxx
@@ -840,7 +840,7 @@ void SfxVirtualMenu::InsertAddOnsMenuItem( Menu* pMenu )
{
pAddonMenu = framework::AddonMenuManager::CreateAddonMenu( xFrame );
}
- catch ( ::com::sun::star::lang::WrappedTargetException )
+ catch ( const ::com::sun::star::lang::WrappedTargetException& )
{
}
More information about the Libreoffice-commits
mailing list