Fix some more memory leaks (#204)