fix macro by denying trailing slashes. also other stuff
This commit is contained in:
@@ -16,7 +16,7 @@ unsafe fn test_nofollow_errors(dir_fd: wasi::Fd) {
|
||||
.expect_err("opening a directory symlink as a directory should fail")
|
||||
.raw_error(),
|
||||
wasi::ERRNO_LOOP,
|
||||
wasi::ERRNO_NOTDIR,
|
||||
wasi::ERRNO_NOTDIR
|
||||
);
|
||||
|
||||
// Try to open it with just O_NOFOLLOW.
|
||||
@@ -25,7 +25,7 @@ unsafe fn test_nofollow_errors(dir_fd: wasi::Fd) {
|
||||
.expect_err("opening a symlink with O_NOFOLLOW should fail")
|
||||
.raw_error(),
|
||||
wasi::ERRNO_LOOP,
|
||||
wasi::ERRNO_ACCES,
|
||||
wasi::ERRNO_ACCES
|
||||
);
|
||||
|
||||
// Try to open it as a directory without O_NOFOLLOW.
|
||||
@@ -70,7 +70,7 @@ unsafe fn test_nofollow_errors(dir_fd: wasi::Fd) {
|
||||
wasi::path_open(dir_fd, 0, "symlink", 0, 0, 0, 0)
|
||||
.expect_err("opening a symlink with NOFOLLOW should fail")
|
||||
.raw_error(),
|
||||
wasi::ERRNO_LOOP,
|
||||
wasi::ERRNO_LOOP
|
||||
);
|
||||
|
||||
// Try to open it as a directory without O_NOFOLLOW.
|
||||
@@ -86,7 +86,7 @@ unsafe fn test_nofollow_errors(dir_fd: wasi::Fd) {
|
||||
)
|
||||
.expect_err("opening a symlink to a file as a directory")
|
||||
.raw_error(),
|
||||
wasi::ERRNO_NOTDIR,
|
||||
wasi::ERRNO_NOTDIR
|
||||
);
|
||||
|
||||
// Clean up.
|
||||
|
||||
Reference in New Issue
Block a user