Doing proper cleanup