summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2016-05-25 20:47:10 +0100
committerCaolán McNamara <caolanm@redhat.com>2016-05-25 21:05:41 +0100
commite954697a9d39e40473fb9f59a791ccb7129e763c (patch)
treebe7d41c1851045a574392319494e49127d8d67a3
parente664254c3efcc611d018f4e813c30f38cc116b06 (diff)
Resolves: tdf#97879 loop in style hierarchy on odt loop
Change-Id: I0098c434b89b6a57e8b888a4d4f643e4d0865d29
-rw-r--r--sw/qa/core/data/odt/pass/tdf97879.odtbin0 -> 20275 bytes
-rw-r--r--xmloff/source/text/txtimp.cxx8
2 files changed, 7 insertions, 1 deletions
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 000000000000..b34526763509
--- /dev/null
+++ b/sw/qa/core/data/odt/pass/tdf97879.odt
Binary files differ
diff --git a/xmloff/source/text/txtimp.cxx b/xmloff/source/text/txtimp.cxx
index 3da0e8b9bc10..08dafafdcbfe 100644
--- a/xmloff/source/text/txtimp.cxx
+++ b/xmloff/source/text/txtimp.cxx
@@ -1380,7 +1380,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;
}
}
}