HomeClusterLabs Projects

Refactor: libcrmcommon: Drop pcmk__xml_cleanup()
4fe477dfa7a8Unpublished

Unpublished Commit ยท Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

Refactor: libcrmcommon: Drop pcmk__xml_cleanup()

xmlCleanupParser() is supposed to be called only immediately before
program exit (or more precisely, when the program is completely finished
using libxml2). So even though we usually isolate libxml2 functions to
appropriate source files, I think it makes sense to call this directly
in pcmk_common_cleanup() alongside qb_log_fini(), as part of cleaning up
external library memory/state.

This means we also must call it directly in crm_xml_cleanup() for
backwards compatibility. And at least for now, we call it in the unit
test cleanup function, since crm_exit()/pcmk_common_cleanup() doesn't
get called when exiting a unit test.

Signed-off-by: Reid Wahl <nrwahl@protonmail.com>

Details

Provenance
nrwahl2Authored on Thu, Apr 24, 2:10 PM
Parents
rP0f863c821609: Refactor: libcrmcommon: Call correct setup functions
Branches
Unknown
Tags
Unknown

Event Timeline