mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-29 11:41:22 +03:00
Remove htmlDefaultSAXHandler from non-SAX1 build
This matches long-standing behavior of the XML counterpart.
This commit is contained in:
@ -6338,7 +6338,9 @@ htmlCreatePushParserCtxt(htmlSAXHandlerPtr sax, void *user_data,
|
||||
if(enc==XML_CHAR_ENCODING_UTF8 || buf->encoder)
|
||||
ctxt->charset=XML_CHAR_ENCODING_UTF8;
|
||||
if (sax != NULL) {
|
||||
#ifdef LIBXML_SAX1_ENABLED
|
||||
if (ctxt->sax != (xmlSAXHandlerPtr) &htmlDefaultSAXHandler)
|
||||
#endif
|
||||
xmlFree(ctxt->sax);
|
||||
ctxt->sax = (htmlSAXHandlerPtr) xmlMalloc(sizeof(htmlSAXHandler));
|
||||
if (ctxt->sax == NULL) {
|
||||
|
Reference in New Issue
Block a user