Margo is not cleaning up Mercury properly
margo_cleanup
, which is used either in margo_finalize
or margo_wait_for_finalize
, is not destroying the instance's hg_context
and hg_class
. At best this causes a leak. At worst, when using a protocol like na+sm
, it makes it impossible to finalize margo and re-initialize it later on.