[ooo-build-commit] patches/dev300

Radek Doulík rodo at kemper.freedesktop.org
Wed Oct 21 07:21:16 PDT 2009


 patches/dev300/apply                       |    2 ++
 patches/dev300/unoxml-fix-empty-xmlns.diff |   13 +++++++++++++
 2 files changed, 15 insertions(+)

New commits:
commit 22abaa119db156d380b14ff7dbc9846b4f474ea7
Author: Radek Doulik <rodo at novell.com>
Date:   Wed Oct 21 16:10:46 2009 +0200

    fix crasher in xml parser
    
    * patches/dev300/apply:
    * patches/dev300/unoxml-fix-empty-xmlns.diff:

diff --git a/patches/dev300/apply b/patches/dev300/apply
index d511f4c..27dbba6 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -3401,3 +3401,5 @@ xmlhelp-build-without-java.diff, rodo
 filter-fix-build-FCFGMerge.cfg.diff, rodo
 store-crash-fix.diff, thorsten
 sd-ppt-fix-document-summary-reading.diff, n#546758, rodo
+# fixes crasher in xml parser
+unoxml-fix-empty-xmlns.diff, rodo
diff --git a/patches/dev300/unoxml-fix-empty-xmlns.diff b/patches/dev300/unoxml-fix-empty-xmlns.diff
new file mode 100644
index 0000000..7a31b3e
--- /dev/null
+++ b/patches/dev300/unoxml-fix-empty-xmlns.diff
@@ -0,0 +1,13 @@
+--- unoxml/source/dom/node.cxx.orig	2009-10-21 15:48:14.000000000 +0200
++++ unoxml/source/dom/node.cxx	2009-10-21 15:49:05.000000000 +0200
+@@ -71,8 +71,9 @@ namespace DOM
+         // add node's namespaces to current context
+         for (xmlNsPtr pNs = pNode->nsDef; pNs != 0; pNs = pNs->next) {
+             const xmlChar *pPrefix = pNs->prefix;
++	    // prefix can be NULL when xmlns attribute is empty (xmlns="")
+             OString prefix(reinterpret_cast<const sal_Char*>(pPrefix),
+-                           strlen(reinterpret_cast<const char*>(pPrefix)));
++                           pPrefix ? strlen(reinterpret_cast<const char*>(pPrefix)) : 0);
+             const xmlChar *pHref = pNs->href;
+             OUString val(reinterpret_cast<const sal_Char*>(pHref),
+                 strlen(reinterpret_cast<const char*>(pHref)),


More information about the ooo-build-commit mailing list