From c4704ba573d18e5c8d3c63b65172a512100f7ad4 Mon Sep 17 00:00:00 2001 From: Jakub Konka Date: Sun, 21 Jul 2019 23:09:18 +0200 Subject: [PATCH] Fix error mapping for fd_seek on Windows --- src/sys/windows/host_impl.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sys/windows/host_impl.rs b/src/sys/windows/host_impl.rs index b591774..d8627b8 100644 --- a/src/sys/windows/host_impl.rs +++ b/src/sys/windows/host_impl.rs @@ -18,7 +18,7 @@ pub fn errno_from_win(error: winx::winerror::WinError) -> host::__wasi_errno_t { ERROR_INVALID_HANDLE | ERROR_INVALID_NAME => host::__WASI_EBADF, ERROR_NOT_ENOUGH_MEMORY | ERROR_OUTOFMEMORY => host::__WASI_ENOMEM, ERROR_DIR_NOT_EMPTY => host::__WASI_ENOTEMPTY, - ERROR_DEV_NOT_EXIST => host::__WASI_ENODEV, + ERROR_DEV_NOT_EXIST => host::__WASI_EINVAL, ERROR_NOT_READY | ERROR_BUSY => host::__WASI_EBUSY, ERROR_NOT_SUPPORTED => host::__WASI_ENOTSUP, ERROR_FILE_EXISTS => host::__WASI_EEXIST,