MCPcopy Create free account
hub / github.com/Kitware/VTK / xmlCleanupCharEncodingHandlers

Function xmlCleanupCharEncodingHandlers

ThirdParty/libxml2/vtklibxml2/encoding.c:1442–1459  ·  view source on GitHub ↗

* xmlCleanupCharEncodingHandlers: * * DEPRECATED: This function will be made private. Call xmlCleanupParser * to free global state but see the warnings there. xmlCleanupParser * should be only called once at program exit. In most cases, you don't * have call cleanup functions at all. * * Cleanup the memory allocated for the char encoding support, it * unregisters all the encoding handlers

Source from the content-addressed store, hash-verified

1440 * unregisters all the encoding handlers and the aliases.
1441 */
1442void
1443xmlCleanupCharEncodingHandlers(void) {
1444 xmlCleanupEncodingAliases();
1445
1446 if (handlers == NULL) return;
1447
1448 for (;nbCharEncodingHandler > 0;) {
1449 nbCharEncodingHandler--;
1450 if (handlers[nbCharEncodingHandler] != NULL) {
1451 if (handlers[nbCharEncodingHandler]->name != NULL)
1452 xmlFree(handlers[nbCharEncodingHandler]->name);
1453 xmlFree(handlers[nbCharEncodingHandler]);
1454 }
1455 }
1456 xmlFree(handlers);
1457 handlers = NULL;
1458 nbCharEncodingHandler = 0;
1459}
1460
1461/**
1462 * xmlRegisterCharEncodingHandler:

Callers 1

xmlCleanupParserFunction · 0.85

Calls 1

Tested by

no test coverage detected