From 3ab30697edac0b02e14783229914c6a76faec366 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sat, 26 Jul 2014 22:27:58 +0200 Subject: Fix bug in C++/Parser Expat support --- debian/changelog | 7 +++ debian/patches/0100-C++Parser_Expat_support.patch | 52 +++++++++++++++++++++++ debian/patches/series | 1 + 3 files changed, 60 insertions(+) create mode 100644 debian/patches/0100-C++Parser_Expat_support.patch diff --git a/debian/changelog b/debian/changelog index bc19a6c..f0b0360 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +xsd (4.0.0-2) unstable; urgency=medium + + * Add debian/patches/0100-C++Parser_Expat_support.patch + - Fix bug in C++/Parser Expat support. + + -- Jörg Frings-Fürst Sat, 26 Jul 2014 21:39:47 +0200 + xsd (4.0.0-1) unstable; urgency=medium * New upstream release. diff --git a/debian/patches/0100-C++Parser_Expat_support.patch b/debian/patches/0100-C++Parser_Expat_support.patch new file mode 100644 index 0000000..1caeb5b --- /dev/null +++ b/debian/patches/0100-C++Parser_Expat_support.patch @@ -0,0 +1,52 @@ +Description: Fix bug in C++/Parser Expat support. +Author: Jörg Frings-Fürst +Reviewed-by: +Last-Update: 2014-07-26 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +Index: trunk/xsd/libxsd/xsd/cxx/parser/expat/elements.hxx +=================================================================== +--- trunk.orig/xsd/libxsd/xsd/cxx/parser/expat/elements.hxx 2014-07-21 08:36:38.000000000 +0200 ++++ trunk/xsd/libxsd/xsd/cxx/parser/expat/elements.hxx 2014-07-26 21:50:06.000000000 +0200 +@@ -51,7 +51,9 @@ + } + }; + +- typedef std::unique_ptr parser_auto_ptr; ++ typedef ++ std::unique_ptr ++ parser_auto_ptr; + #else + // Simple auto pointer for Expat's XML_Parser object. + // +Index: trunk/xsd/libxsd/xsd/cxx/parser/expat/elements.txx +=================================================================== +--- trunk.orig/xsd/libxsd/xsd/cxx/parser/expat/elements.txx 2014-07-21 08:36:38.000000000 +0200 ++++ trunk/xsd/libxsd/xsd/cxx/parser/expat/elements.txx 2014-07-26 21:55:23.000000000 +0200 +@@ -283,9 +283,10 @@ + throw std::bad_alloc (); + + if (system_id || public_id) +- parse_begin (parser, system_id ? *system_id : *public_id, eh); ++ parse_begin ( ++ parser.get (), system_id ? *system_id : *public_id, eh); + else +- parse_begin (parser, eh); ++ parse_begin (parser.get (), eh); + + // Temporarily unset the exception failbit. Also clear the + // fail bit when we reset the old state if it was caused +@@ -309,9 +310,10 @@ + // + break; + } +- +- if (XML_Parse ( +- parser, buf, is.gcount (), is.eof ()) == XML_STATUS_ERROR) ++ if (XML_Parse (parser.get (), ++ buf, ++ is.gcount (), ++ is.eof ()) == XML_STATUS_ERROR) + { + r = false; + break; diff --git a/debian/patches/series b/debian/patches/series index 8ac7078..0f2af3c 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1 +1,2 @@ +0100-C++Parser_Expat_support.patch 0001-xsd_xsdcxx-rename.patch -- cgit v1.2.3