WIP fix minor leaks [skip ci]