1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-10-24 13:33:01 +03:00

fix: avoid segfault at exit when using custom memory functions

This extends the fix introduced by 956534e to Windows processes
dynamically loading libxml2.

Closes #256.
This commit is contained in:
Mike Dalessio
2021-05-20 13:38:54 -04:00
parent b48e77cf4f
commit a7b9f3ebdf

View File

@@ -14672,6 +14672,7 @@ xmlInitParser(void) {
return; return;
#if defined(_WIN32) && (!defined(LIBXML_STATIC) || defined(LIBXML_STATIC_FOR_DLL)) #if defined(_WIN32) && (!defined(LIBXML_STATIC) || defined(LIBXML_STATIC_FOR_DLL))
if (xmlFree == free)
atexit(xmlCleanupParser); atexit(xmlCleanupParser);
#endif #endif