diff options
author | Nick Wellnhofer <wellnhofer@aevum.de> | 2022-11-24 16:38:47 +0100 |
---|---|---|
committer | Nick Wellnhofer <wellnhofer@aevum.de> | 2022-11-25 15:02:04 +0100 |
commit | cecd364dd2f55810ab27eb0f44b35197a1a358d8 (patch) | |
tree | 294ea3c3eb5782852a4c249625943e801af67183 /SAX2.c | |
parent | 1406b20fe9c2f5e9bd1dd11cfa08bc3d81b294c2 (diff) | |
download | libxml2-cecd364dd2f55810ab27eb0f44b35197a1a358d8.tar.gz |
parser: Don't call *DefaultSAXHandlerInit from xmlInitParser
Change the default handler definitions to match the result after calling
the initialization functions.
This makes sure that no thread-local variables are accessed when calling
xmlInitParser.
Diffstat (limited to 'SAX2.c')
-rw-r--r-- | SAX2.c | 12 |
1 files changed, 2 insertions, 10 deletions
@@ -2937,7 +2937,7 @@ xmlSAX2InitDefaultSAXHandler(xmlSAXHandler *hdlr, int warning) /** * xmlDefaultSAXHandlerInit: * - * DEPRECATED: This function will be made private. Call xmlInitParser to + * DEPRECATED: This function is a no-op. Call xmlInitParser to * initialize the library. * * Initialize the default SAX2 handler @@ -2945,9 +2945,6 @@ xmlSAX2InitDefaultSAXHandler(xmlSAXHandler *hdlr, int warning) void xmlDefaultSAXHandlerInit(void) { -#ifdef LIBXML_SAX1_ENABLED - xmlSAXVersion((xmlSAXHandlerPtr) &xmlDefaultSAXHandler, 1); -#endif /* LIBXML_SAX1_ENABLED */ } #ifdef LIBXML_HTML_ENABLED @@ -2998,17 +2995,12 @@ xmlSAX2InitHtmlDefaultSAXHandler(xmlSAXHandler *hdlr) /** * htmlDefaultSAXHandlerInit: * - * DEPRECATED: This function will be made private. Call xmlInitParser to + * DEPRECATED: This function is a no-op. Call xmlInitParser to * initialize the library. - * - * Initialize the default SAX handler */ void htmlDefaultSAXHandlerInit(void) { -#ifdef LIBXML_SAX1_ENABLED - xmlSAX2InitHtmlDefaultSAXHandler((xmlSAXHandlerPtr) &htmlDefaultSAXHandler); -#endif } #endif /* LIBXML_HTML_ENABLED */ |