Skip to content

Commit

Permalink
ignore env in wasm_exec_node.js
Browse files Browse the repository at this point in the history
  • Loading branch information
syumai committed Jan 6, 2024
1 parent 7529cef commit 1ccb909
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion misc/wasm/wasm_exec_node.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ require("./wasm_exec");

const go = new Go();
go.argv = process.argv.slice(2);
go.env = Object.assign({ TMPDIR: require("os").tmpdir() }, process.env);
// to prevent `total length of command line and environment variables exceeds limit` error, ignore env.
// go.env = Object.assign({ TMPDIR: require("os").tmpdir() }, process.env);
go.exit = process.exit;
WebAssembly.instantiate(fs.readFileSync(process.argv[2]), go.importObject).then((result) => {
process.on("exit", (code) => { // Node.js exits if no event handler is pending
Expand Down

0 comments on commit 1ccb909

Please sign in to comment.