fixed small memory leak when files were closed with linting problems on them