Skip to content

Commit

Permalink
Merge pull request #385 from eriksjolund/add-O_DIRECTORY
Browse files Browse the repository at this point in the history
writer: Add O_DIRECTORY
  • Loading branch information
cgwalters authored Oct 25, 2024
2 parents a82572c + 56e33e2 commit 8cedf32
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion libcomposefs/lcfs-writer.c
Original file line number Diff line number Diff line change
Expand Up @@ -1508,7 +1508,8 @@ struct lcfs_node_s *lcfs_build(int dirfd, const char *fname, int buildflags,
return node;
}

dfd = openat(dirfd, fname, O_RDONLY | O_NOFOLLOW | O_CLOEXEC, 0);
dfd = openat(dirfd, fname,
O_DIRECTORY | O_RDONLY | O_NOFOLLOW | O_CLOEXEC, 0);
if (dfd < 0) {
errsv = errno;
goto fail;
Expand Down

0 comments on commit 8cedf32

Please sign in to comment.