Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: VFS should not walk circular symlinks #17093

Merged
merged 1 commit into from
Apr 18, 2024

Commits on Apr 17, 2024

  1. fix: VFS should not walk circular symlinks

    As of rust-lang#6246, rust-analyzer follows symlinks. This can introduce an
    infinite loop if symlinks point to parent directories.
    
    Considering that rust-lang#6246 was added in 2020 without many bug reports,
    this is clearly a rare occurrence. However, I am observing
    rust-analyzer hang on projects that have symlinks of the form:
    
    ```
    test/a_symlink -> ../../
    ```
    
    Ignore symlinks that only point to the parent directories, as this is
    more robust but still allows typical symlink usage patterns.
    Wilfred committed Apr 17, 2024
    Configuration menu
    Copy the full SHA
    bd133ee View commit details
    Browse the repository at this point in the history