diff options
Diffstat (limited to 'games/ufoai/patches/bug-949301-mxml.patch')
-rw-r--r-- | games/ufoai/patches/bug-949301-mxml.patch | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/games/ufoai/patches/bug-949301-mxml.patch b/games/ufoai/patches/bug-949301-mxml.patch new file mode 100644 index 000000000000..678a0b8e3bee --- /dev/null +++ b/games/ufoai/patches/bug-949301-mxml.patch @@ -0,0 +1,29 @@ +From: Markus Koschany <apo@debian.org> +Date: Mon, 17 Feb 2020 22:49:06 +0100 +Subject: bug 949301 mxml + +Bug-Debian: https://bugs.debian.org/949301 +Origin: https://sourceforge.net/p/ufoai/code/ci/163073ab9527cdaa33d77a713b8e46ff462a2b5c/ +--- + src/common/xml.cpp | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +diff --git a/src/common/xml.cpp b/src/common/xml.cpp +index 1629c90..8323752 100644 +--- a/src/common/xml.cpp ++++ b/src/common/xml.cpp +@@ -519,8 +519,13 @@ static mxml_type_t mxml_ufo_type_cb (xmlNode_t* node) + /* You can lookup attributes and/or use the + * element name, hierarchy, etc... */ + const char* type = mxmlElementGetAttr(node, "type"); +- if (type == nullptr) ++ if (type == nullptr) { ++#ifdef MXML_MAJOR_VERSION ++ type = mxmlGetElement(node); ++#else + type = node->value.element.name; ++#endif ++ } + + if (!strcmp(type, "int")) + return MXML_INTEGER; |