Commit b7230ee5 authored by Xiyue Deng's avatar Xiyue Deng

* New upstream release.

  + Fix memory leak in class xmlpp::Document::Init.  (Closes: #469809)
  + Drop 10_gcc4.3_include_fix.patch and 20_file_id_fix.patch,
    merged upstream.
* Fix section in doc-base reference.
parent 2122dbf4
libxml++2.6 (2.22.0-1) unstable; urgency=low
* New upstream release.
+ Fix memory leak in class xmlpp::Document::Init. (Closes: #469809)
+ Drop 10_gcc4.3_include_fix.patch and 20_file_id_fix.patch,
merged upstream.
* Fix section in doc-base reference.
-- Deng Xiyue <manphiz-guest@users.alioth.debian.org> Sat, 08 Mar 2008 00:55:05 +0800
libxml++2.6 (2.20.0-2) unstable; urgency=low
* Refined debian/rules to set variables SHARED_PKG and DOC_PKG by sed
......@@ -16,11 +26,8 @@ libxml++2.6 (2.20.0-2) unstable; urgency=low
cdbs to >= 0.4.51 to avoid empty debug package bug.
* Update watch version to 3, and drop 'debian uupdate' as not
necessarily required.
* Fix section in doc-base references.
* Add 10_document_memory_leak_fix.patch for possible memory leak.
(Closes: #469809)
-- Deng Xiyue <manphiz-guest@users.alioth.debian.org> Fri, 07 Mar 2008 17:34:03 +0800
-- Deng Xiyue <manphiz-guest@users.alioth.debian.org> Thu, 28 Feb 2008 18:27:38 +0800
libxml++2.6 (2.20.0-1) unstable; urgency=low
......
diff -urN libxml++-2.20.0/libxml++/document.cc libxml++-2.20.0~/libxml++/document.cc
--- libxml++-2.20.0/libxml++/document.cc 2007-08-29 16:22:51.000000000 +0800
+++ libxml++-2.20.0~/libxml++/document.cc 2008-03-07 16:51:17.000000000 +0800
@@ -137,11 +137,16 @@
Document::Init::Init()
{
- xmlInitParser(); //Not always necessary, but necessary for thread safety.
- xmlRegisterNodeDefault(on_libxml_construct);
- xmlDeregisterNodeDefault(on_libxml_destruct);
- xmlThrDefRegisterNodeDefault(on_libxml_construct);
- xmlThrDefDeregisterNodeDefault(on_libxml_destruct);
+ xmlInitParser(); //Not always necessary, but necessary for thread safety.
+ xmlRegisterNodeDefault(on_libxml_construct);
+ xmlDeregisterNodeDefault(on_libxml_destruct);
+ xmlThrDefRegisterNodeDefault(on_libxml_construct);
+ xmlThrDefDeregisterNodeDefault(on_libxml_destruct);
+}
+
+Document::Init::~Init()
+{
+ xmlCleanupParser(); //as per xmlInitParser(), or memory leak will happen.
}
Document::Init Document::init_;
diff -urN libxml++-2.20.0/libxml++/document.h libxml++-2.20.0~/libxml++/document.h
--- libxml++-2.20.0/libxml++/document.h 2007-09-11 16:11:24.000000000 +0800
+++ libxml++-2.20.0~/libxml++/document.h 2008-03-07 17:10:31.000000000 +0800
@@ -53,6 +53,7 @@
{
public:
Init();
+ virtual ~Init();
};
friend class DomParser;
--- libxml++/parsers/parser.cc~ 2007-04-02 13:06:44.000000000 +0000
+++ libxml++/parsers/parser.cc 2007-04-02 13:06:59.000000000 +0000
@@ -9,6 +9,7 @@
#include <libxml/parser.h>
#include <cstdarg> //For va_list.
+#include <memory> //For auto_ptr.
namespace xmlpp {
--- libxml++/parsers/textreader.h~ 2007-04-02 13:08:26.000000000 +0000
+++ libxml++/parsers/textreader.h 2007-04-02 13:08:33.000000000 +0000
@@ -12,6 +12,8 @@
#include <glibmm/ustring.h>
+#include <memory>
+
extern "C"
{
struct _xmlTextReader;
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment