summaryrefslogtreecommitdiff
path: root/stoc
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-04-16 13:52:02 +0200
committerPetr Mladek <pmladek@suse.cz>2013-05-06 17:36:35 +0200
commit2557c2796c0c4c533e31a28ca59fe3296e582f0a (patch)
tree5a8c750fc33d69e44ce2914adab69e3bb522546e /stoc
parent8443407096ac4e6848c38874aaebcef01c585f4f (diff)
rhbz#867808 Do not throw RuntimeException by pointer
(cherry picked from commit e46564a0a6a74da90785a1b910d33e2b5bfdcfd9, plus 63b4633cf7b0da9eba63e752cec72cb10ed9d93e "Related: rhbz#867808 if one person threw by pointer..." and 336353a87e6003e685aab87ea74a158546e1f297 "Related rhbz#867808: More apparently bogus 'throw new ...' in C++ code") Signed-off-by: Petr Mladek <pmladek@suse.cz> Conflicts: bridges/test/java_uno/nativethreadpool/testnativethreadpoolclient.cxx bridges/test/java_uno/nativethreadpool/testnativethreadpoolserver.cxx sdext/source/presenter/PresenterController.cxx stoc/source/registry_tdprovider/functiondescription.cxx stoc/source/registry_tdprovider/methoddescription.cxx toolkit/source/awt/vclxwindow1.cxx Change-Id: I22b7d3d642e7ee0488d6b726a331d328065bbee7 Reviewed-on: https://gerrit.libreoffice.org/3418 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com> Signed-off-by: Petr Mladek <pmladek@suse.cz>
Diffstat (limited to 'stoc')
-rw-r--r--stoc/source/registry_tdprovider/functiondescription.cxx4
-rw-r--r--stoc/source/registry_tdprovider/methoddescription.cxx2
2 files changed, 3 insertions, 3 deletions
diff --git a/stoc/source/registry_tdprovider/functiondescription.cxx b/stoc/source/registry_tdprovider/functiondescription.cxx
index 8840451355fe..3cb96351192e 100644
--- a/stoc/source/registry_tdprovider/functiondescription.cxx
+++ b/stoc/source/registry_tdprovider/functiondescription.cxx
@@ -71,7 +71,7 @@ FunctionDescription::getExceptions() const {
try {
any = m_manager->getByHierarchicalName(name);
} catch (const css::container::NoSuchElementException & e) {
- throw new css::uno::RuntimeException(
+ throw css::uno::RuntimeException(
(rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.container.NoSuchElementException: "))
@@ -81,7 +81,7 @@ FunctionDescription::getExceptions() const {
if (!(any >>= exceptions[i])
|| exceptions[i]->getTypeClass() != css::uno::TypeClass_EXCEPTION)
{
- throw new css::uno::RuntimeException(
+ throw css::uno::RuntimeException(
(rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM("not an exception type: "))
+ name),
diff --git a/stoc/source/registry_tdprovider/methoddescription.cxx b/stoc/source/registry_tdprovider/methoddescription.cxx
index fd2d6c3343aa..f018d1fc1d20 100644
--- a/stoc/source/registry_tdprovider/methoddescription.cxx
+++ b/stoc/source/registry_tdprovider/methoddescription.cxx
@@ -90,7 +90,7 @@ css::uno::Reference< css::reflection::XTypeDescription > Parameter::getType()
m_manager->getByHierarchicalName(m_typeName),
css::uno::UNO_QUERY_THROW);
} catch (const css::container::NoSuchElementException & e) {
- throw new css::uno::RuntimeException(
+ throw css::uno::RuntimeException(
(rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.container.NoSuchElementException: "))