Skip to content

Commit

Permalink
Handling deprecation warnings in new version of libxml
Browse files Browse the repository at this point in the history
  • Loading branch information
gershnik committed Oct 3, 2024
1 parent 62cc349 commit 13def10
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/xml_wrapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,14 @@ struct XmlParserInit {
XmlParserInit() {
xmlInitParser();
xmlSetGenericErrorFunc(nullptr, XmlParserInit::errorFunc);
#if LIBXML_VERSION < 21300
xmlThrDefSetGenericErrorFunc(nullptr, XmlParserInit::errorFunc);
#endif

xmlSetStructuredErrorFunc(nullptr, XmlParserInit::structuredErrorFunc);
#if LIBXML_VERSION < 21300
xmlThrDefSetStructuredErrorFunc(nullptr, XmlParserInit::structuredErrorFunc);
#endif
}
~XmlParserInit() {
xmlCleanupParser();
Expand Down

0 comments on commit 13def10

Please sign in to comment.