[oe-commits] Martin Jansa : libxml2: add recipe for 2.7.8 version

git version control git at git.openembedded.org
Fri Nov 19 10:17:53 UTC 2010


Module: openembedded.git
Branch: master
Commit: a941898ca5004a3e81e7a8fff64b993942cdf7fb
URL:    http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=a941898ca5004a3e81e7a8fff64b993942cdf7fb

Author: Martin Jansa <Martin.Jansa at gmail.com>
Date:   Thu Nov 18 15:03:51 2010 +0100

libxml2: add recipe for 2.7.8 version

Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>

---

 .../0cbeb50ee03ce582a0c979c70d8fbf030e270c37.patch |   29 ++++++++++++++++++
 .../df83c17e5a2646bd923f75e5e507bc80d73c9722.patch |   32 ++++++++++++++++++++
 .../fec31bcd452e77c10579467ca87a785b41115de6.patch |   28 +++++++++++++++++
 recipes/libxml/libxml2_2.7.8.bb                    |   12 +++++++
 4 files changed, 101 insertions(+), 0 deletions(-)

diff --git a/recipes/libxml/libxml2-2.7.8/0cbeb50ee03ce582a0c979c70d8fbf030e270c37.patch b/recipes/libxml/libxml2-2.7.8/0cbeb50ee03ce582a0c979c70d8fbf030e270c37.patch
new file mode 100644
index 0000000..f94350d
--- /dev/null
+++ b/recipes/libxml/libxml2-2.7.8/0cbeb50ee03ce582a0c979c70d8fbf030e270c37.patch
@@ -0,0 +1,29 @@
+From 0cbeb50ee03ce582a0c979c70d8fbf030e270c37 Mon Sep 17 00:00:00 2001
+From: Daniel Veillard <veillard at redhat.com>
+Date: Mon, 15 Nov 2010 11:06:29 +0000
+Subject: Fix a potential memory access error
+
+in case of a previus allocation error
+---
+diff --git a/xpath.c b/xpath.c
+index 4d6826d..81e33f6 100644
+--- a/xpath.c
++++ b/xpath.c
+@@ -3575,13 +3575,13 @@ xmlXPathNodeSetAdd(xmlNodeSetPtr cur, xmlNodePtr val) {
+     } else if (cur->nodeNr == cur->nodeMax) {
+         xmlNodePtr *temp;
+ 
+-        cur->nodeMax *= 2;
+-	temp = (xmlNodePtr *) xmlRealloc(cur->nodeTab, cur->nodeMax *
++	temp = (xmlNodePtr *) xmlRealloc(cur->nodeTab, cur->nodeMax * 2 *
+ 				      sizeof(xmlNodePtr));
+ 	if (temp == NULL) {
+ 	    xmlXPathErrMemory(NULL, "growing nodeset\n");
+ 	    return;
+ 	}
++        cur->nodeMax *= 2;
+ 	cur->nodeTab = temp;
+     }
+     if (val->type == XML_NAMESPACE_DECL) {
+--
+cgit v0.8.3.1
diff --git a/recipes/libxml/libxml2-2.7.8/df83c17e5a2646bd923f75e5e507bc80d73c9722.patch b/recipes/libxml/libxml2-2.7.8/df83c17e5a2646bd923f75e5e507bc80d73c9722.patch
new file mode 100644
index 0000000..3509a48
--- /dev/null
+++ b/recipes/libxml/libxml2-2.7.8/df83c17e5a2646bd923f75e5e507bc80d73c9722.patch
@@ -0,0 +1,32 @@
+From df83c17e5a2646bd923f75e5e507bc80d73c9722 Mon Sep 17 00:00:00 2001
+From: Daniel Veillard <veillard at redhat.com>
+Date: Wed, 17 Nov 2010 13:12:14 +0000
+Subject: Fix a potential freeing error in XPath
+
+---
+diff --git a/xpath.c b/xpath.c
+index 81e33f6..1447be5 100644
+--- a/xpath.c
++++ b/xpath.c
+@@ -11763,11 +11763,15 @@ xmlXPathCompOpEvalPositionalPredicate(xmlXPathParserContextPtr ctxt,
+ 
+ 	    if ((ctxt->error != XPATH_EXPRESSION_OK) || (res == -1)) {
+ 	        xmlXPathObjectPtr tmp;
+-		/* pop the result */
++		/* pop the result if any */
+ 		tmp = valuePop(ctxt);
+-		xmlXPathReleaseObject(xpctxt, tmp);
+-		/* then pop off contextObj, which will be freed later */
+-		valuePop(ctxt);
++                if (tmp != contextObj)
++                    /*
++                     * Free up the result
++                     * then pop off contextObj, which will be freed later
++                     */
++                    xmlXPathReleaseObject(xpctxt, tmp);
++                    valuePop(ctxt);
+ 		goto evaluation_error;
+ 	    }
+ 
+--
+cgit v0.8.3.1
diff --git a/recipes/libxml/libxml2-2.7.8/fec31bcd452e77c10579467ca87a785b41115de6.patch b/recipes/libxml/libxml2-2.7.8/fec31bcd452e77c10579467ca87a785b41115de6.patch
new file mode 100644
index 0000000..1705941
--- /dev/null
+++ b/recipes/libxml/libxml2-2.7.8/fec31bcd452e77c10579467ca87a785b41115de6.patch
@@ -0,0 +1,28 @@
+From fec31bcd452e77c10579467ca87a785b41115de6 Mon Sep 17 00:00:00 2001
+From: Daniel Veillard <veillard at redhat.com>
+Date: Thu, 18 Nov 2010 10:07:24 +0000
+Subject: Small fix for previous commit
+
+---
+diff --git a/xpath.c b/xpath.c
+index 1447be5..8b56189 100644
+--- a/xpath.c
++++ b/xpath.c
+@@ -11765,13 +11765,14 @@ xmlXPathCompOpEvalPositionalPredicate(xmlXPathParserContextPtr ctxt,
+ 	        xmlXPathObjectPtr tmp;
+ 		/* pop the result if any */
+ 		tmp = valuePop(ctxt);
+-                if (tmp != contextObj)
++                if (tmp != contextObj) {
+                     /*
+                      * Free up the result
+                      * then pop off contextObj, which will be freed later
+                      */
+                     xmlXPathReleaseObject(xpctxt, tmp);
+                     valuePop(ctxt);
++                }
+ 		goto evaluation_error;
+ 	    }
+ 
+--
+cgit v0.8.3.1
diff --git a/recipes/libxml/libxml2_2.7.8.bb b/recipes/libxml/libxml2_2.7.8.bb
new file mode 100644
index 0000000..6b72e30
--- /dev/null
+++ b/recipes/libxml/libxml2_2.7.8.bb
@@ -0,0 +1,12 @@
+require libxml2.inc
+
+SRC_URI += "\
+  file://0cbeb50ee03ce582a0c979c70d8fbf030e270c37.patch \
+  file://df83c17e5a2646bd923f75e5e507bc80d73c9722.patch \
+  file://fec31bcd452e77c10579467ca87a785b41115de6.patch \
+"
+
+PR = "${INC_PR}.0"
+
+SRC_URI[archive.md5sum] = "8127a65e8c3b08856093099b52599c86"
+SRC_URI[archive.sha256sum] = "cda23bc9ebd26474ca8f3d67e7d1c4a1f1e7106364b690d822e009fdc3c417ec"





More information about the Openembedded-commits mailing list