From 6acd5c45c764d81aea1539e66adbfadb51df0aa3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= Date: Wed, 21 Jan 2015 15:25:03 +0000 Subject: [PATCH] Resolves: fdo#87601 specific html doc hangs on load Change-Id: I67f472d72efe123b533d4d94be0084986c0e8349 --- sw/qa/core/data/html/pass/fdo87601-1.html | 100 ++++++++++++++++++++++ sw/source/filter/html/swhtml.cxx | 2 +- 2 files changed, 101 insertions(+), 1 deletion(-) create mode 100644 sw/qa/core/data/html/pass/fdo87601-1.html diff --git a/sw/qa/core/data/html/pass/fdo87601-1.html b/sw/qa/core/data/html/pass/fdo87601-1.html new file mode 100644 index 000000000000..b33f11c1b0a7 --- /dev/null +++ b/sw/qa/core/data/html/pass/fdo87601-1.html @@ -0,0 +1,100 @@ + + + + + + + + + Print + 100 + + + + + +
+
+
+

+

+ Your bug here +

+

+
+ + + + + + + + + + + + + + + + + +
xx
xx
xx
xx
+
+ + + + + + + + + + +
xxx
xxx
xxx
xxx
+ + diff --git a/sw/source/filter/html/swhtml.cxx b/sw/source/filter/html/swhtml.cxx index d2c6212dc8ac..138a64b71ef8 100644 --- a/sw/source/filter/html/swhtml.cxx +++ b/sw/source/filter/html/swhtml.cxx @@ -3074,7 +3074,7 @@ void SwHTMLParser::EndAttr( _HTMLAttr* pAttr, _HTMLAttr **ppDepAttr, rText, pAttr->GetSttCnt() ); sal_Int32 nScriptEnd = g_pBreakIt->GetBreakIter() ->endOfScript( rText, pAttr->GetSttCnt(), nScriptTxt ); - while( nScriptEnd < nEndCnt ) + while (nScriptEnd < nEndCnt && nScriptEnd != -1) { if( nScriptItem == nScriptTxt ) {