[ooo-build-commit] Branch 'ooo-build-3-1-1' - patches/dev300

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


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

New commits:
commit 9d4c66ae31d3ed224083dcc17ba07a9aee748c20
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 1c4b215..f095b8a 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -3474,3 +3474,5 @@ emf+-driver-string.diff, n#519715, rodo
 sd-print-fix-pageoffset.diff, n#537931, rodo
 svx-ppt-import-fix-bullet-size.diff, n#515972, rodo
 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