Skip to content

xsdconvert: xmlGetLastError(): fix invalid pointer conversion

Vadim Yanitskiy requested to merge vyanitskiy/titan.core:master into master

This patch fixes the following errors observed with libxml2 v2.12.6:

XMLParser.cc: In static member function ‘static void XMLParser::warningHandler(void*, const char*, ...)’:
XMLParser.cc:193:38: error: invalid conversion from ‘const xmlError*’ {aka ‘const _xmlError*’} to ‘xmlErrorPtr’ {aka ‘_xmlError*’} [-fpermissive]
  193 |   xmlErrorPtr error = xmlGetLastError();
      |                       ~~~~~~~~~~~~~~~^~
      |                                      |
      |                                      const xmlError* {aka const _xmlError*}
XMLParser.cc: In static member function ‘static void XMLParser::errorHandler(void*, const char*, ...)’:
XMLParser.cc:213:38: error: invalid conversion from ‘const xmlError*’ {aka ‘const _xmlError*’} to ‘xmlErrorPtr’ {aka ‘_xmlError*’} [-fpermissive]
  213 |   xmlErrorPtr error = xmlGetLastError();
      |                       ~~~~~~~~~~~~~~~^~
      |                                      |
      |                                      const xmlError* {aka const _xmlError*}
Edited by Vadim Yanitskiy

Merge request reports

Loading