When does tempFile get cleaned up in this codepath?