Skip symlinks targeting ancestors of walker root to prevent resource exhaustion
Before adoption: this commit came in with the history the project adopted, so no landing records it.
When --walker=follow is used, symlinks like Wine's z: -> / cause fzf to traverse the entire root filesystem. fastwalk's built-in loop detection only catches this on the second pass, but a single pass through / already causes severe CPU and memory exhaustion. This fix resolves each symlink-to-directory target to its absolute real path and skips it if it is an ancestor of (or equal to) the walker root. Close #4710
authored by Junegunn Choi · committed by Junegunn Choi · parent 2ae7367 · Browse files · 2 files+37 added−0 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
2 files+37 added−0 removed
- other:+37 added−0 removed