mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-10-24 13:33:01 +03:00
Fix regression introduced with 477c7f6a
The 'inSubset' member is actually used by the SAX2 handlers. Store extra parser state in 'hasPErefs'.
This commit is contained in:
14
HTMLparser.c
14
HTMLparser.c
@@ -5160,9 +5160,9 @@ htmlParseLookupSequence(htmlParserCtxtPtr ctxt, xmlChar first,
|
|||||||
|
|
||||||
if (ctxt->checkIndex > base) {
|
if (ctxt->checkIndex > base) {
|
||||||
base = ctxt->checkIndex;
|
base = ctxt->checkIndex;
|
||||||
/* Abuse inSubset member to restore current state. */
|
/* Abuse hasPErefs member to restore current state. */
|
||||||
incomment = ctxt->inSubset & 1 ? 1 : 0;
|
incomment = ctxt->hasPErefs & 1 ? 1 : 0;
|
||||||
invalue = ctxt->inSubset & 2 ? 1 : 0;
|
invalue = ctxt->hasPErefs & 2 ? 1 : 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (in->buf == NULL) {
|
if (in->buf == NULL) {
|
||||||
@@ -5240,12 +5240,12 @@ htmlParseLookupSequence(htmlParserCtxtPtr ctxt, xmlChar first,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
ctxt->checkIndex = base;
|
ctxt->checkIndex = base;
|
||||||
/* Abuse inSubset member to track current state. */
|
/* Abuse hasPErefs member to track current state. */
|
||||||
ctxt->inSubset = 0;
|
ctxt->hasPErefs = 0;
|
||||||
if (incomment)
|
if (incomment)
|
||||||
ctxt->inSubset |= 1;
|
ctxt->hasPErefs |= 1;
|
||||||
if (invalue)
|
if (invalue)
|
||||||
ctxt->inSubset |= 2;
|
ctxt->hasPErefs |= 2;
|
||||||
#ifdef DEBUG_PUSH
|
#ifdef DEBUG_PUSH
|
||||||
if (next == 0)
|
if (next == 0)
|
||||||
xmlGenericError(xmlGenericErrorContext,
|
xmlGenericError(xmlGenericErrorContext,
|
||||||
|
|||||||
Reference in New Issue
Block a user