summaryrefslogtreecommitdiff
path: root/unodevtools
diff options
context:
space:
mode:
authorTakeshi Abe <tabe@fixedpoint.jp>2012-01-08 03:34:57 +0900
committerTakeshi Abe <tabe@fixedpoint.jp>2012-01-08 03:35:43 +0900
commitff580eb39b46646309feba447f6bf485124db6b1 (patch)
tree5dbea85aed84589c0c1bd9859f487b9af0df7558 /unodevtools
parent5b031b4ea68df5ca210a5631c801414b476d8094 (diff)
catch exception by constant reference
Diffstat (limited to 'unodevtools')
-rw-r--r--unodevtools/source/skeletonmaker/cppcompskeleton.cxx6
-rw-r--r--unodevtools/source/skeletonmaker/javacompskeleton.cxx2
-rw-r--r--unodevtools/source/skeletonmaker/skeletonmaker.cxx4
3 files changed, 6 insertions, 6 deletions
diff --git a/unodevtools/source/skeletonmaker/cppcompskeleton.cxx b/unodevtools/source/skeletonmaker/cppcompskeleton.cxx
index 648efa6c667e..97ba560658cd 100644
--- a/unodevtools/source/skeletonmaker/cppcompskeleton.cxx
+++ b/unodevtools/source/skeletonmaker/cppcompskeleton.cxx
@@ -333,7 +333,7 @@ void generateXAddInBodies(std::ostream& o, const OString & classname)
"::rtl::OUString(),\n "
"sDISPLAYNAME);\n if (sDisplayName.equals(aDisplayName))\n"
" return functions[i];\n }\n }\n"
- " catch ( css::uno::RuntimeException & e ) {\n throw e;\n }\n"
+ " catch ( const css::uno::RuntimeException & e ) {\n throw e;\n }\n"
" catch ( css::uno::Exception & ) {\n }\n return ret;\n}\n\n";
o << "::rtl::OUString SAL_CALL " << classname << "getDisplayFunctionName(const "
@@ -406,7 +406,7 @@ void generateXCompatibilityNamesBodies(std::ostream& o, const OString & classnam
" } while ( nIndex >= 0 );\n\n "
"seqLocalizedNames[i].Locale = aLocale;\n "
"seqLocalizedNames[i].Name = sCompatibilityName;\n }"
- "\n }\n }\n catch ( css::uno::RuntimeException & e ) {\n "
+ "\n }\n }\n catch ( const css::uno::RuntimeException & e ) {\n "
"throw e;\n }\n catch ( css::uno::Exception & ) {\n }\n\n"
" return seqLocalizedNames;\n}\n\n";
}
@@ -580,7 +580,7 @@ void generateAddinConstructorAndHelper(std::ostream& o,
" buf.makeStringAndClear()), css::uno::UNO_QUERY);\n"
" xPropSet->getPropertyValue(\n "
"::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(propName))) >>= ret;\n }\n"
- " catch ( css::uno::RuntimeException & e ) {\n throw e;\n }\n"
+ " catch ( const css::uno::RuntimeException & e ) {\n throw e;\n }\n"
" catch ( css::uno::Exception & ) {\n }\n return ret;\n";
}
o <<"}\n\n";
diff --git a/unodevtools/source/skeletonmaker/javacompskeleton.cxx b/unodevtools/source/skeletonmaker/javacompskeleton.cxx
index ba8851c19d12..1b71276af7d4 100644
--- a/unodevtools/source/skeletonmaker/javacompskeleton.cxx
+++ b/unodevtools/source/skeletonmaker/javacompskeleton.cxx
@@ -975,7 +975,7 @@ void generateSkeleton(ProgramOptions const & options,
delete pofs;
OSL_VERIFY(makeValidTypeFile(compFileName, tmpFileName, sal_False));
}
- } catch(CannotDumpException& e) {
+ } catch(const CannotDumpException& e) {
std::cerr << "ERROR: " << e.m_message.getStr() << "\n";
if ( !standardout ) {
diff --git a/unodevtools/source/skeletonmaker/skeletonmaker.cxx b/unodevtools/source/skeletonmaker/skeletonmaker.cxx
index ddd2ab43de06..119b778535bc 100644
--- a/unodevtools/source/skeletonmaker/skeletonmaker.cxx
+++ b/unodevtools/source/skeletonmaker/skeletonmaker.cxx
@@ -338,10 +338,10 @@ SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, /*argv*/)
}
}
- } catch (CannotDumpException & e) {
+ } catch (const CannotDumpException & e) {
std::cout.flush();
std::cerr << "\nError: " << e.m_message << std::endl;
- } catch(Exception& e) {
+ } catch(const Exception& e) {
std::cout.flush();
std::cerr
<< "\nError: "