[Libreoffice-commits] core.git: Branch 'libreoffice-4-2' - package/source

Stephan Bergmann sbergman at redhat.com
Tue May 20 04:51:50 PDT 2014


 package/source/xstor/xstorage.cxx |   14 ++++++++++----
 1 file changed, 10 insertions(+), 4 deletions(-)

New commits:
commit 164e10869f91b75db03b09f53e1467098b3e6b93
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Tue May 20 11:12:40 2014 +0200

    fdo#78949 Handle (SAXParse-)Exception that can't pass getAllRelationships
    
    ...like it was already done in the similar else branch of
    ReadRelInfoIfNecessary.  The call site at GetAllRelationshipsIfAny will
    translate an m_nRelInfoStatus that remained RELINFO_NOT_INIT into an
    IOException.
    
    Change-Id: I79c601acd23b3b0020c7b4de4c20b0282524bce1
    (cherry picked from commit 423921b085de43f53e42f957889dd96378d2c3c4)
    Reviewed-on: https://gerrit.libreoffice.org/9411
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/package/source/xstor/xstorage.cxx b/package/source/xstor/xstorage.cxx
index 9e2ffb7..8775561 100644
--- a/package/source/xstor/xstorage.cxx
+++ b/package/source/xstor/xstorage.cxx
@@ -572,13 +572,19 @@ void OStorage_Impl::ReadRelInfoIfNecessary()
     {
         // Init from original stream
         uno::Reference< io::XInputStream > xRelInfoStream = GetRelInfoStreamForName( OUString() );
-        if ( xRelInfoStream.is() )
-            m_aRelInfo = ::comphelper::OFOPXMLHelper::ReadRelationsInfoSequence(
+        try
+        {
+            if ( xRelInfoStream.is() )
+                m_aRelInfo = ::comphelper::OFOPXMLHelper::ReadRelationsInfoSequence(
                                     xRelInfoStream,
                                     "_rels/.rels",
                                     m_xContext );
-
-        m_nRelInfoStatus = RELINFO_READ;
+            m_nRelInfoStatus = RELINFO_READ;
+        }
+        catch (css::uno::Exception & e)
+        {
+            SAL_INFO("package.xstor", "caught Exception " << e.Message);
+        }
     }
     else if ( m_nRelInfoStatus == RELINFO_CHANGED_STREAM )
     {


More information about the Libreoffice-commits mailing list