[Libreoffice-commits] core.git: desktop/source offapi/com

Caolán McNamara caolanm at redhat.com
Tue May 27 06:00:23 PDT 2014


 desktop/source/deployment/registry/dp_backend.cxx         |   12 +++++----
 desktop/source/deployment/registry/help/dp_help.cxx       |    6 +++-
 desktop/source/deployment/registry/inc/dp_backend.h       |    6 +++-
 desktop/source/deployment/registry/package/dp_package.cxx |    8 ++++--
 desktop/source/deployment/registry/sfwk/dp_sfwk.cxx       |   18 +++++++++-----
 offapi/com/sun/star/deployment/XPackage.idl               |    5 ++-
 6 files changed, 36 insertions(+), 19 deletions(-)

New commits:
commit 42119194fd5f66e393b9b53692d2330016d144d6
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue May 27 13:12:02 2014 +0100

    coverity#706499 Uncaught exception
    
    also coverity#706500 and coverity#706502 and coverity#706503
    
    Change-Id: If8c76f9fea669f3397a3db65fefaabe101bf9c35

diff --git a/desktop/source/deployment/registry/dp_backend.cxx b/desktop/source/deployment/registry/dp_backend.cxx
index fb5c05d..69b918b 100644
--- a/desktop/source/deployment/registry/dp_backend.cxx
+++ b/desktop/source/deployment/registry/dp_backend.cxx
@@ -515,8 +515,10 @@ OUString Package::getDescription() throw (
 }
 
 
-OUString Package::getLicenseText() throw (
-    deployment::ExtensionRemovedException,RuntimeException, std::exception)
+OUString Package::getLicenseText()throw (
+    deployment::DeploymentException,
+    deployment::ExtensionRemovedException,
+    RuntimeException, std::exception)
 {
     if (m_bRemoved)
         throw deployment::ExtensionRemovedException();
@@ -751,6 +753,7 @@ PackageRegistryBackend * Package::getMyBackend() const
     }
     return pBackend;
 }
+
 OUString Package::getRepositoryName()
     throw (RuntimeException, std::exception)
 {
@@ -759,7 +762,8 @@ OUString Package::getRepositoryName()
 }
 
 beans::Optional< OUString > Package::getRegistrationDataURL()
-        throw (deployment::ExtensionRemovedException,
+        throw (deployment::DeploymentException,
+               deployment::ExtensionRemovedException,
                css::uno::RuntimeException, std::exception)
 {
     if (m_bRemoved)
@@ -773,8 +777,6 @@ sal_Bool Package::isRemoved()
     return m_bRemoved;
 }
 
-
-
 Package::TypeInfo::~TypeInfo()
 {
 }
diff --git a/desktop/source/deployment/registry/help/dp_help.cxx b/desktop/source/deployment/registry/help/dp_help.cxx
index c3ecbd4..74259ae 100644
--- a/desktop/source/deployment/registry/help/dp_help.cxx
+++ b/desktop/source/deployment/registry/help/dp_help.cxx
@@ -84,7 +84,8 @@ class BackendImpl : public ::dp_registry::backend::PackageRegistryBackend
 
         //XPackage
         virtual css::beans::Optional< OUString > SAL_CALL getRegistrationDataURL()
-            throw (deployment::ExtensionRemovedException, css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+            throw (deployment::DeploymentException, deployment::ExtensionRemovedException,
+                   css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     };
     friend class PackageImpl;
 
@@ -356,7 +357,8 @@ void BackendImpl::PackageImpl::processPackage_(
 }
 
 beans::Optional< OUString > BackendImpl::PackageImpl::getRegistrationDataURL()
-    throw (deployment::ExtensionRemovedException,
+    throw (deployment::DeploymentException,
+           deployment::ExtensionRemovedException,
            css::uno::RuntimeException, std::exception)
 {
     if (m_bRemoved)
diff --git a/desktop/source/deployment/registry/inc/dp_backend.h b/desktop/source/deployment/registry/inc/dp_backend.h
index 618fc46..8e1a75e 100644
--- a/desktop/source/deployment/registry/inc/dp_backend.h
+++ b/desktop/source/deployment/registry/inc/dp_backend.h
@@ -227,7 +227,8 @@ public:
         throw (css::deployment::ExtensionRemovedException,
                css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     virtual OUString SAL_CALL getLicenseText()
-        throw (css::deployment::ExtensionRemovedException,
+        throw (css::deployment::DeploymentException,
+               css::deployment::ExtensionRemovedException,
                css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     virtual css::uno::Sequence< OUString > SAL_CALL
     getUpdateInformationURLs()
@@ -253,7 +254,8 @@ public:
     virtual OUString SAL_CALL getRepositoryName()
         throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     virtual css::beans::Optional< OUString > SAL_CALL getRegistrationDataURL()
-        throw (css::deployment::ExtensionRemovedException,
+        throw (css::deployment::DeploymentException,
+               css::deployment::ExtensionRemovedException,
                css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
     virtual sal_Bool SAL_CALL isRemoved()
         throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
diff --git a/desktop/source/deployment/registry/package/dp_package.cxx b/desktop/source/deployment/registry/package/dp_package.cxx
index a852f23..875d423 100644
--- a/desktop/source/deployment/registry/package/dp_package.cxx
+++ b/desktop/source/deployment/registry/package/dp_package.cxx
@@ -182,7 +182,9 @@ class BackendImpl : public ImplBaseT
             throw (deployment::ExtensionRemovedException, RuntimeException, std::exception) SAL_OVERRIDE;
 
         virtual OUString SAL_CALL getLicenseText()
-            throw (deployment::ExtensionRemovedException, RuntimeException, std::exception) SAL_OVERRIDE;
+            throw (deployment::DeploymentException,
+                   deployment::ExtensionRemovedException,
+                   RuntimeException, std::exception) SAL_OVERRIDE;
 
         virtual void SAL_CALL exportTo(
             OUString const & destFolderURL, OUString const & newTitle,
@@ -999,7 +1001,9 @@ OUString BackendImpl::PackageImpl::getDescription()
 
 
 OUString BackendImpl::PackageImpl::getLicenseText()
-    throw (deployment::ExtensionRemovedException, RuntimeException, std::exception)
+    throw (deployment::DeploymentException,
+           deployment::ExtensionRemovedException,
+           RuntimeException, std::exception)
 {
     if (m_bRemoved)
         throw deployment::ExtensionRemovedException();
diff --git a/desktop/source/deployment/registry/sfwk/dp_sfwk.cxx b/desktop/source/deployment/registry/sfwk/dp_sfwk.cxx
index 86c0791..bbf8dbf 100644
--- a/desktop/source/deployment/registry/sfwk/dp_sfwk.cxx
+++ b/desktop/source/deployment/registry/sfwk/dp_sfwk.cxx
@@ -75,8 +75,12 @@ class BackendImpl : public ::dp_registry::backend::PackageRegistryBackend
             OUString const & url, OUString const & libType, bool bRemoved,
             OUString const & identifier);
         // XPackage
-        virtual OUString SAL_CALL getDescription() throw (RuntimeException, std::exception) SAL_OVERRIDE;
-        virtual OUString SAL_CALL getLicenseText() throw (RuntimeException, std::exception) SAL_OVERRIDE;
+        virtual OUString SAL_CALL getDescription()
+            throw (deployment::ExtensionRemovedException,
+                   RuntimeException, std::exception) SAL_OVERRIDE;
+        virtual OUString SAL_CALL getLicenseText()
+            throw (deployment::ExtensionRemovedException,
+                   RuntimeException, std::exception) SAL_OVERRIDE;
     };
     friend class PackageImpl;
 
@@ -116,7 +120,9 @@ BackendImpl * BackendImpl::PackageImpl::getMyBackend() const
     return pBackend;
 }
 
-OUString BackendImpl::PackageImpl::getDescription() throw (RuntimeException, std::exception)
+OUString BackendImpl::PackageImpl::getDescription()
+    throw (deployment::ExtensionRemovedException,
+           RuntimeException, std::exception)
 {
     if (m_descr.isEmpty())
         return Package::getDescription();
@@ -124,13 +130,13 @@ OUString BackendImpl::PackageImpl::getDescription() throw (RuntimeException, std
         return m_descr;
 }
 
-
-OUString BackendImpl::PackageImpl::getLicenseText() throw (RuntimeException, std::exception)
+OUString BackendImpl::PackageImpl::getLicenseText()
+    throw (deployment::ExtensionRemovedException,
+           RuntimeException, std::exception)
 {
     return Package::getDescription();
 }
 
-
 BackendImpl::PackageImpl::PackageImpl(
     ::rtl::Reference<BackendImpl> const & myBackend,
     OUString const & url, OUString const & libType, bool bRemoved,
diff --git a/offapi/com/sun/star/deployment/XPackage.idl b/offapi/com/sun/star/deployment/XPackage.idl
index d0b942f..c44e12f 100644
--- a/offapi/com/sun/star/deployment/XPackage.idl
+++ b/offapi/com/sun/star/deployment/XPackage.idl
@@ -265,7 +265,8 @@ interface XPackage
                 license
     */
     string getLicenseText()
-         raises (ExtensionRemovedException);
+         raises (DeploymentException,
+                 ExtensionRemovedException);
 
     /** returns a sequence of update information URLs.
 
@@ -347,7 +348,7 @@ interface XPackage
         be an empty string.
     */
     com::sun::star::beans::Optional<string> getRegistrationDataURL()
-        raises (ExtensionRemovedException);
+        raises (DeploymentException, ExtensionRemovedException);
 
     /** indicates if this object represents a removed extension or extension
         item. This is the case when it was created by providing


More information about the Libreoffice-commits mailing list