try/catch finally. so we make sure tmp is deleted