0
Fork 0
mirror of https://codeberg.org/ziglang/zig synced 2026-11-18 07:05:05 +00:00
zig/lib
Jakub Konka b0ee911c23 wasi: always grant fd_readdir right
Since v0.23 release of Wasmtime, if we want to iterate a directory
Y then directory Y needed to have been granted `fd_readdir` right.
However, it is now also required for directory X to carry `fd_readdir`
right, and so on, up-chain all the way until we reach the preopen
(which possesses all rights by default).

This caused problems for us since our libstd implementation is more
fine-grained and allowed for parent dirs not to carry the right while
allow for iterating on its children. My proposal here is to always
grant `fd_readdir` right as part of
`std.fs.Dir.OpenDirOptions.access_sub_paths`. This seems to be the
approach taken by Rust also, plus we should be justified to take this
approach since WASI is experimental and snapshot1 will be discontinued
eventually and replaced with a new approach to access management
that will require a complete rewrite of our libstd anyhow.
History 2021-06-08 05:48:33 +02:00
..
include llvm12: sync with llvmorg-12.0.0-rc2 2021-02-26 13:44:33 -08:00
libc update mingw-w64 crt files to v9.0.0 2021-06-04 09:49:36 -07:00
libcxx llvm12: sync with llvmorg-12.0.0-rc2 2021-02-26 13:44:33 -08:00
libcxxabi llvm12: sync with llvmorg-12.0.0-rc2 2021-02-26 13:44:33 -08:00
libunwind llvm12: sync with llvmorg-12.0.0-rc2 2021-02-26 13:44:33 -08:00
std wasi: always grant fd_readdir right 2021-06-08 05:48:33 +02:00
tsan stage2: fix Cache deadlock and build more of TSAN 2020-12-24 01:18:48 -07:00