[Libreoffice-commits] core.git: Branch 'libreoffice-5-1' - sw/qa xmloff/source

Caolán McNamara caolanm at redhat.com
Mon May 30 08:33:45 UTC 2016


 sw/qa/core/data/odt/pass/tdf97879.odt |binary
 xmloff/source/text/txtimp.cxx         |    8 +++++++-
 2 files changed, 7 insertions(+), 1 deletion(-)

New commits:
commit 3c4c153f596e3b378a01bdabb78008c02a1d2ff6
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed May 25 20:47:10 2016 +0100

    Resolves: tdf#97879 loop in style hierarchy on odt loop
    
    Change-Id: I0098c434b89b6a57e8b888a4d4f643e4d0865d29
    (cherry picked from commit e954697a9d39e40473fb9f59a791ccb7129e763c)
    Reviewed-on: https://gerrit.libreoffice.org/25498
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>

diff --git a/sw/qa/core/data/odt/pass/tdf97879.odt b/sw/qa/core/data/odt/pass/tdf97879.odt
new file mode 100644
index 0000000..b345267
Binary files /dev/null and b/sw/qa/core/data/odt/pass/tdf97879.odt differ
diff --git a/xmloff/source/text/txtimp.cxx b/xmloff/source/text/txtimp.cxx
index 76c7127..5b740f1 100644
--- a/xmloff/source/text/txtimp.cxx
+++ b/xmloff/source/text/txtimp.cxx
@@ -1382,7 +1382,13 @@ static bool lcl_HasListStyle( const OUString& sStyleName,
                 else
                 {
                     // search list style at parent
-                    xStyle.set( xPropState, UNO_QUERY );
+                    Reference<XStyle> xParentStyle(xPropState, UNO_QUERY);
+                    if (xStyle == xParentStyle)
+                    {
+                        // error case
+                        return true;
+                    }
+                    xStyle = xParentStyle;
                 }
             }
         }


More information about the Libreoffice-commits mailing list