[BUG] Refactor recursive tree traversal to avoid Stack Overflow #14
Labels
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
geomind_code/my_fs#14
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The pack_unpack tests in src/lib.rs currently require a manually spawned thread with a 16MB stack to prevent crashes.
Issue: This indicates that the recursive visitor pattern used for tree traversal is not safe for default stack sizes (typically 2MB). Processing deep directory structures in production will likely lead to stack overflow crashes.
Proposed Fix: Refactor the tree traversal logic to use an iterative approach with a heap-allocated stack.