vfs: add dirent parent pointer

Signed-off-by: Michael Shaw <m@michaelsshaw.com>
This commit is contained in:
Michael Shaw 2026-07-12 10:47:58 -04:00
commit d2c698ac0a
7 changed files with 25 additions and 13 deletions

View file

@ -103,6 +103,7 @@ static ssize_t read_next(fs_t *fs, const char *file, rbtree_t *list, dirent_t **
write_unlock(&parent->inode->rwlock);
if (res == 0) {
new_dent->fs = parent->fs;
new_dent->parent = parent;
*out = new_dent;
} else {
inode_dec_ref(existing_ino);