From b35c0ae4ffce43b881d66efe74a19f1bf6299331 Mon Sep 17 00:00:00 2001 From: Takeshi Abe Date: Mon, 9 Jan 2012 03:16:33 +0900 Subject: catch exception by constant reference --- xmlsecurity/tools/standalone/csfit/certmngr.cxx | 2 +- xmlsecurity/tools/standalone/csfit/decrypter.cxx | 2 +- xmlsecurity/tools/standalone/csfit/encrypter.cxx | 2 +- xmlsecurity/tools/standalone/csfit/signer.cxx | 2 +- xmlsecurity/tools/standalone/csfit/verifier.cxx | 2 +- xmlsecurity/tools/standalone/mscsfit/certmngr.cxx | 2 +- xmlsecurity/tools/standalone/mscsfit/decrypter.cxx | 2 +- xmlsecurity/tools/standalone/mscsfit/encrypter.cxx | 2 +- xmlsecurity/tools/standalone/mscsfit/signer.cxx | 2 +- xmlsecurity/tools/standalone/mscsfit/verifier.cxx | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) (limited to 'xmlsecurity') diff --git a/xmlsecurity/tools/standalone/csfit/certmngr.cxx b/xmlsecurity/tools/standalone/csfit/certmngr.cxx index b5257911623c..82d8d5b9e4e2 100644 --- a/xmlsecurity/tools/standalone/csfit/certmngr.cxx +++ b/xmlsecurity/tools/standalone/csfit/certmngr.cxx @@ -169,7 +169,7 @@ int SAL_CALL main( int argc, char **argv ) sal_Int32 validity = pSecEnv->verifyCertificate( xPersonalCerts[i] ) ; fprintf( stdout, "The certificate validities are %d\n", validity ) ; } - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/csfit/decrypter.cxx b/xmlsecurity/tools/standalone/csfit/decrypter.cxx index c3d27a887b8f..a39352c629ce 100644 --- a/xmlsecurity/tools/standalone/csfit/decrypter.cxx +++ b/xmlsecurity/tools/standalone/csfit/decrypter.cxx @@ -236,7 +236,7 @@ int SAL_CALL main( int argc, char **argv ) OSL_ENSURE( xDecrRes.is() , "Decryptor - " "Cannot decrypt the xml document" ) ; - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/csfit/encrypter.cxx b/xmlsecurity/tools/standalone/csfit/encrypter.cxx index 2000b037991c..bcf9c275eaaf 100644 --- a/xmlsecurity/tools/standalone/csfit/encrypter.cxx +++ b/xmlsecurity/tools/standalone/csfit/encrypter.cxx @@ -269,7 +269,7 @@ int SAL_CALL main( int argc, char **argv ) OSL_ENSURE( xTemplate.is() , "Encryptor - " "Cannot encrypt the xml document" ) ; - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/csfit/signer.cxx b/xmlsecurity/tools/standalone/csfit/signer.cxx index ee21c0d5fec6..96cf72d2ae71 100644 --- a/xmlsecurity/tools/standalone/csfit/signer.cxx +++ b/xmlsecurity/tools/standalone/csfit/signer.cxx @@ -326,7 +326,7 @@ int SAL_CALL main( int argc, char **argv ) OSL_ENSURE( xTemplate.is() , "Signer - " "Cannot generate the xml signature" ) ; - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/csfit/verifier.cxx b/xmlsecurity/tools/standalone/csfit/verifier.cxx index ecca4020c719..a624f793eefd 100644 --- a/xmlsecurity/tools/standalone/csfit/verifier.cxx +++ b/xmlsecurity/tools/standalone/csfit/verifier.cxx @@ -313,7 +313,7 @@ int SAL_CALL main( int argc, char **argv ) } else { printf( "Signature is VALID!\n" ) ; } - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/mscsfit/certmngr.cxx b/xmlsecurity/tools/standalone/mscsfit/certmngr.cxx index 9ff7ae36e20a..04ddd9860f7f 100644 --- a/xmlsecurity/tools/standalone/mscsfit/certmngr.cxx +++ b/xmlsecurity/tools/standalone/mscsfit/certmngr.cxx @@ -135,7 +135,7 @@ int SAL_CALL main( int argc, char **argv ) fprintf( stdout, "The certificate validities are %d\n", validity ) ; } - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/mscsfit/decrypter.cxx b/xmlsecurity/tools/standalone/mscsfit/decrypter.cxx index b2a08629880b..259d9cef89fa 100644 --- a/xmlsecurity/tools/standalone/mscsfit/decrypter.cxx +++ b/xmlsecurity/tools/standalone/mscsfit/decrypter.cxx @@ -210,7 +210,7 @@ int SAL_CALL main( int argc, char **argv ) OSL_ENSURE( xDecrRes.is() , "Decryptor - " "Cannot decrypt the xml document" ) ; - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/mscsfit/encrypter.cxx b/xmlsecurity/tools/standalone/mscsfit/encrypter.cxx index 0312f271e0ea..1645163a1894 100644 --- a/xmlsecurity/tools/standalone/mscsfit/encrypter.cxx +++ b/xmlsecurity/tools/standalone/mscsfit/encrypter.cxx @@ -267,7 +267,7 @@ int SAL_CALL main( int argc, char **argv ) { fprintf( stdout, "Operation fails.\n") ; } - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/mscsfit/signer.cxx b/xmlsecurity/tools/standalone/mscsfit/signer.cxx index 0c7fbecba9fa..9e96e4fc40ec 100644 --- a/xmlsecurity/tools/standalone/mscsfit/signer.cxx +++ b/xmlsecurity/tools/standalone/mscsfit/signer.cxx @@ -299,7 +299,7 @@ int SAL_CALL main( int argc, char **argv ) { fprintf( stdout, "Operation fails.\n") ; } - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } diff --git a/xmlsecurity/tools/standalone/mscsfit/verifier.cxx b/xmlsecurity/tools/standalone/mscsfit/verifier.cxx index 74d827dd08e6..2278d10db4ef 100644 --- a/xmlsecurity/tools/standalone/mscsfit/verifier.cxx +++ b/xmlsecurity/tools/standalone/mscsfit/verifier.cxx @@ -296,7 +296,7 @@ int SAL_CALL main( int argc, char **argv ) { fprintf( stdout, "Operation fails.\n") ; } - } catch( Exception& e ) { + } catch( const Exception& e ) { fprintf( stderr , "Error Message: %s\n" , OUStringToOString( e.Message , RTL_TEXTENCODING_ASCII_US ).getStr() ) ; goto done ; } -- cgit