You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix symlink handling in FUSE and overlay filesystem
The FUSE handlers were using stat() which follows symlinks, causing
symlinks to directories to be incorrectly reported as directories.
This broke operations like `rm -rf` on pnpm's node_modules which uses
symlinks extensively.
Changes:
- Use lstat() instead of stat() in FUSE lookup(), getattr(), unlink(),
and rmdir() to correctly identify symlinks
- Add EISDIR check in unlink() to reject directory removal attempts
- Fix overlay remove() to detect symlinks and skip directory-empty
checks for them
- Use lstat() in overlay when checking base layer existence
- Add test for symlink handling
Fixes the "Is a directory" error when removing symlinks to directories.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
0 commit comments