Merge branch 'xml_sax2'

This commit is contained in:
rfm 2025-01-17 10:44:44 +00:00
commit 1d977212f6

View file

@ -2992,7 +2992,11 @@ hasInternalSubsetFunction(void *ctx)
has = [HANDLER hasInternalSubset]; has = [HANDLER hasInternalSubset];
if (has < 0) if (has < 0)
{ {
has = TREEFUN(hasInternalSubset, (ctx)); #if LIBXML_VERSION >= 20900
has = xmlSAX2HasInternalSubset (ctx);
#else
has = xmlInternalSubset (ctxt);
#endif
} }
return has; return has;
} }
@ -3006,7 +3010,11 @@ hasExternalSubsetFunction(void *ctx)
has = [HANDLER hasExternalSubset]; has = [HANDLER hasExternalSubset];
if (has < 0) if (has < 0)
{ {
has = TREEFUN(hasExternalSubset, (ctx)); #if LIBXML_VERSION >= 20900
has = xmlSAX2HasExternalSubset (ctx);
#else
has = xmlExternalSubset (ctx);
#endif
} }
return has; return has;
} }
@ -3720,6 +3728,7 @@ fatalErrorFunction(void *ctx, const unsigned char *msg, ...)
LIB->isStandalone = (void*) isStandaloneFunction; LIB->isStandalone = (void*) isStandaloneFunction;
LIB->hasInternalSubset = (void*) hasInternalSubsetFunction; LIB->hasInternalSubset = (void*) hasInternalSubsetFunction;
LIB->hasExternalSubset = (void*) hasExternalSubsetFunction; LIB->hasExternalSubset = (void*) hasExternalSubsetFunction;
LIB->resolveEntity = (void*) resolveEntityFunction;
LIB->getEntity = (void*) getEntityIgnoreExternal; LIB->getEntity = (void*) getEntityIgnoreExternal;
LIB->entityDecl = (void*) entityDeclFunction; LIB->entityDecl = (void*) entityDeclFunction;
LIB->notationDecl = (void*) notationDeclFunction; LIB->notationDecl = (void*) notationDeclFunction;
@ -3738,7 +3747,6 @@ fatalErrorFunction(void *ctx, const unsigned char *msg, ...)
LIB->fatalError = (void*) fatalErrorFunction; LIB->fatalError = (void*) fatalErrorFunction;
LIB->getParameterEntity = (void*) getParameterEntityFunction; LIB->getParameterEntity = (void*) getParameterEntityFunction;
LIB->cdataBlock = (void*) cdataBlockFunction; LIB->cdataBlock = (void*) cdataBlockFunction;
LIB->resolveEntity = (void*) resolveEntityFunction;
#undef LIB #undef LIB
return YES; return YES;
} }
@ -3840,6 +3848,7 @@ fatalErrorFunction(void *ctx, const unsigned char *msg, ...)
SETCB(isStandalone, isStandalone); SETCB(isStandalone, isStandalone);
SETCB(hasInternalSubset, hasInternalSubset); SETCB(hasInternalSubset, hasInternalSubset);
SETCB(hasExternalSubset, hasExternalSubset); SETCB(hasExternalSubset, hasExternalSubset);
LIB->resolveEntity = resolveEntityFunction;
SETCB(getEntity, getEntity:); SETCB(getEntity, getEntity:);
if (LIB->getEntity != getEntityFunction) if (LIB->getEntity != getEntityFunction)
{ {
@ -3897,6 +3906,7 @@ fatalErrorFunction(void *ctx, const unsigned char *msg, ...)
LIB->isStandalone = (void*)isStandaloneFunction; LIB->isStandalone = (void*)isStandaloneFunction;
LIB->hasInternalSubset = (void*)hasInternalSubsetFunction; LIB->hasInternalSubset = (void*)hasInternalSubsetFunction;
LIB->hasExternalSubset = (void*)hasExternalSubsetFunction; LIB->hasExternalSubset = (void*)hasExternalSubsetFunction;
LIB->resolveEntity = (void*)resolveEntityFunction;
LIB->getEntity = (void*)getEntityFunction; LIB->getEntity = (void*)getEntityFunction;
LIB->entityDecl = (void*)entityDeclFunction; LIB->entityDecl = (void*)entityDeclFunction;
LIB->notationDecl = (void*)notationDeclFunction; LIB->notationDecl = (void*)notationDeclFunction;