summaryrefslogtreecommitdiff
path: root/media-libs/musicbrainz/files/musicbrainz-5.1.0-libxml2-2.12-compat.patch
blob: a835ffbb0f2e074acad2f2fc2d5d3d9e07bc88e1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
Fix build with <libxml2-2.12.
--- a/src/xmlParser.cc
+++ b/src/xmlParser.cc
@@ -57,7 +57,7 @@ XMLNode *XMLRootNode::parseFile(const std::string &filename, XMLResults* results
 
     doc = xmlParseFile(filename.c_str());
     if ((doc == NULL) && (results != NULL)) {
-        const xmlError *error = xmlGetLastError();
+        const xmlError *error = (const xmlError*) xmlGetLastError();
         results->message = error->message;
         results->line = error->line;
         results->code = error->code;
@@ -72,7 +72,7 @@ XMLNode *XMLRootNode::parseString(const std::string &xml, XMLResults* results)
 
     doc = xmlParseMemory(xml.c_str(), xml.length());
     if ((doc == NULL) && (results != NULL)) {
-        const xmlError *error = xmlGetLastError();
+        const xmlError *error = (const xmlError*) xmlGetLastError();
         results->message = error->message;
         results->line = error->line;
         results->code = error->code;