Skip to content

Commit

Permalink
namei: Set namedata.dirfd in path_openat
Browse files Browse the repository at this point in the history
This fixes fstat breakage.

Fixes: dc767a8 ("vfs: Change inode_operations->stat and ->link's
prototypes")
Signed-off-by: Pedro Falcato <[email protected]>
  • Loading branch information
heatd committed Jan 21, 2025
1 parent b9a280a commit 59e40e6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions kernel/kernel/fs/namei.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1533,6 +1533,7 @@ int path_openat(int dirfd, const char *name, unsigned int flags, struct path *pa
{
nameidata namedata{std::string_view{name, strlen(name)}};
namedata.lookup_flags = flags;
namedata.dirfd = dirfd;

int err = namei_lookup(namedata);
if (err < 0)
Expand Down

0 comments on commit 59e40e6

Please sign in to comment.