More work on pointer cleanup, and an exception refactor