[Libreoffice-bugs] [Bug 127461] data provider crashes LibreOffice when clicking "Apply Changes"
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Tue Sep 10 08:04:30 UTC 2019
https://bugs.documentfoundation.org/show_bug.cgi?id=127461
--- Comment #2 from Julien Nabet <serval2412 at yahoo.fr> ---
This patch prevents from crashing:
diff --git a/sc/source/ui/dataprovider/htmldataprovider.cxx
b/sc/source/ui/dataprovider/htmldataprovider.cxx
index bbe6dd3c514b..30ae31bc3759 100644
--- a/sc/source/ui/dataprovider/htmldataprovider.cxx
+++ b/sc/source/ui/dataprovider/htmldataprovider.cxx
@@ -192,6 +192,13 @@ void HTMLFetchThread::execute()
OString aID = OUStringToOString(maID, RTL_TEXTENCODING_UTF8);
xmlXPathContextPtr pXmlXpathCtx = xmlXPathNewContext(pHtmlPtr);
xmlXPathObjectPtr pXmlXpathObj =
xmlXPathEvalExpression(BAD_CAST(aID.getStr()), pXmlXpathCtx);
+
+ if (!pXmlXpathObj)
+ {
+ xmlXPathFreeContext(pXmlXpathCtx);
+ return;
+ }
+
xmlNodeSetPtr pXmlNodes = pXmlXpathObj->nodesetval;
if (pXmlNodes->nodeNr == 0)
However, there's no error message or something.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20190910/692083f2/attachment.html>
More information about the Libreoffice-bugs
mailing list