[infer][buck] catch the correct exception when calling os.unlink on some non-existing file

Reviewed By: jvillard

Differential Revision: D8156486

fbshipit-source-id: 699e60d
master
Jeremy Dubreil 7 years ago committed by Facebook Github Bot
parent 1d62441918
commit 0588e26ee6

@ -209,7 +209,7 @@ def cleanup(temp_files):
shutil.rmtree(file) shutil.rmtree(file)
else: else:
os.unlink(file) os.unlink(file)
except IOError: except OSError:
logging.error('Could not remove %s' % file) logging.error('Could not remove %s' % file)

Loading…
Cancel
Save