Upgrade WASI version to wasi_snapshot_preview1 (#1691)

wasm: Upgrade WASI version to wasi_snapshot_preview1

Addresses #1647.
This commit is contained in:
Federico G. Schwindt
2021-03-15 11:41:37 +00:00
committed by GitHub
parent 7d1ce24be5
commit 303acf5ed6
3 changed files with 13 additions and 15 deletions
+2 -2
View File
@@ -247,8 +247,8 @@
const timeOrigin = Date.now() - performance.now();
this.importObject = {
wasi_unstable: {
// https://github.com/bytecodealliance/wasmtime/blob/master/docs/WASI-api.md#__wasi_fd_write
wasi_snapshot_preview1: {
// https://github.com/WebAssembly/WASI/blob/main/phases/snapshot/docs.md#fd_write
fd_write: function(fd, iovs_ptr, iovs_len, nwritten_ptr) {
let nwritten = 0;
if (fd == 1) {