Skip to content

Commit 13def10

Browse files
committed
Handling deprecation warnings in new version of libxml
1 parent 62cc349 commit 13def10

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/xml_wrapper.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,14 @@ struct XmlParserInit {
6464
XmlParserInit() {
6565
xmlInitParser();
6666
xmlSetGenericErrorFunc(nullptr, XmlParserInit::errorFunc);
67+
#if LIBXML_VERSION < 21300
6768
xmlThrDefSetGenericErrorFunc(nullptr, XmlParserInit::errorFunc);
69+
#endif
6870

6971
xmlSetStructuredErrorFunc(nullptr, XmlParserInit::structuredErrorFunc);
72+
#if LIBXML_VERSION < 21300
7073
xmlThrDefSetStructuredErrorFunc(nullptr, XmlParserInit::structuredErrorFunc);
74+
#endif
7175
}
7276
~XmlParserInit() {
7377
xmlCleanupParser();

0 commit comments

Comments
 (0)