even better, clean up after exceptions as well