Files
wazero/internal/sys/testdata
Crypt Keeper 2e13f57f56 wasi: enforce fd_preXXX functions only work on pre-opened files (#919)
At the moment, the only pre-open support we have is the file system
itself (root a.k.a. / or file-descriptor 3). We may in the future add
the ability to pre-open sockets, but in any case, this is where we are
today.

This change hardens logic around fd_preXXX functions, ensuring they only
work on actual pre-opens. This also fixes the path returned in filestat
as we sometimes returned a full path, when typically the basename is the
only part that can be returned.

Signed-off-by: Adrian Cole <adrian@tetrate.io>
2022-12-13 16:42:53 +09:00
..