summaryrefslogtreecommitdiff
path: root/package/source/zippackage
diff options
context:
space:
mode:
authorTakeshi Abe <tabe@fixedpoint.jp>2011-12-21 21:57:16 +0900
committerTakeshi Abe <tabe@fixedpoint.jp>2011-12-21 21:57:54 +0900
commit7958f8244cc3e554b1339b14c7e589dfcbb0526c (patch)
tree8654a25c98b3338cc9f8c4377c89d4dce06387ad /package/source/zippackage
parent7167559379cd44e0160ba20c69cbb6954887e32b (diff)
catch exception by constant reference
Diffstat (limited to 'package/source/zippackage')
-rw-r--r--package/source/zippackage/ZipPackage.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/package/source/zippackage/ZipPackage.cxx b/package/source/zippackage/ZipPackage.cxx
index 78980280372e..c07e7a142992 100644
--- a/package/source/zippackage/ZipPackage.cxx
+++ b/package/source/zippackage/ZipPackage.cxx
@@ -1025,7 +1025,7 @@ void ZipPackage::WriteMimetypeMagicFile( ZipOutputStream& aZipOut )
aZipOut.write( aType, 0, nBufferLength );
aZipOut.closeEntry();
}
- catch ( ::com::sun::star::io::IOException & r )
+ catch ( const ::com::sun::star::io::IOException & r )
{
throw WrappedTargetException(
OUString( RTL_CONSTASCII_USTRINGPARAM ( OSL_LOG_PREFIX "Error adding mimetype to the ZipOutputStream!" ) ),
@@ -1419,7 +1419,7 @@ void SAL_CALL ZipPackage::commitChanges()
{
xTempSeek->seek( 0 );
}
- catch( uno::Exception& r )
+ catch( const uno::Exception& r )
{
throw WrappedTargetException( OUString( RTL_CONSTASCII_USTRINGPARAM ( OSL_LOG_PREFIX "Temporary file should be seekable!" ) ),
static_cast < OWeakObject * > ( this ), makeAny ( r ) );
@@ -1444,7 +1444,7 @@ void SAL_CALL ZipPackage::commitChanges()
// after successful truncation the original file contents are already lost
xTruncate->truncate();
}
- catch( uno::Exception& r )
+ catch( const uno::Exception& r )
{
throw WrappedTargetException( OUString( RTL_CONSTASCII_USTRINGPARAM ( OSL_LOG_PREFIX "This package is read only!" ) ),
static_cast < OWeakObject * > ( this ), makeAny ( r ) );
@@ -1543,7 +1543,7 @@ void SAL_CALL ZipPackage::commitChanges()
// if the file is still not corrupted, it can become after the next step
aContent.executeCommand ( OUString ( RTL_CONSTASCII_USTRINGPARAM ( "transfer" ) ), aAny );
}
- catch ( ::com::sun::star::uno::Exception& r )
+ catch ( const ::com::sun::star::uno::Exception& r )
{
if ( bCanBeCorrupted )
DisconnectFromTargetAndThrowException_Impl( xTempInStream );