]> git.proxmox.com Git - wasi-libc.git/commit
Use `ENOENT` rather than `ENOTCAPABLE` for missing preopens. (#370)
authorDan Gohman <dev@sunfishcode.online>
Wed, 21 Dec 2022 23:47:53 +0000 (15:47 -0800)
committerGitHub <noreply@github.com>
Wed, 21 Dec 2022 23:47:53 +0000 (15:47 -0800)
commitb8aa39947d086b1b360fc8e3c5a30ab91c391b0d
treef2fb14df93f8dd65c661b9e1e04f7dbd6ba7cf70
parentb36b752bd7e48d16ee5f9487ccd1ec2fe2ba358e
Use `ENOENT` rather than `ENOTCAPABLE` for missing preopens. (#370)

When a user calls `open` with a path that does not have a corresponding
preopen, set errno to `ENOENT` rather than `ENOTCAPABLE`. This
conceptually represents an attempt to open a path which has not been
provided within the sandbox, so it's more accurately represented as
"not present" rather than "insufficient capabilities".
libc-bottom-half/sources/posix.c