Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid TOCTOU errors in cache initialization (#10884)
## Summary I believe this should close #10880? The `.gitignore` creation seems ok, since it truncates, but using `cachedir::is_tagged` followed by `cachedir::add_tag` is not safe, as `cachedir::add_tag` _fails_ if the file already exists. This also matches the structure of the code in `uv`. Closes #10880.
- Loading branch information