From ff7ef06ab65e4ebc4725be929e1828a8ad41ee22 Mon Sep 17 00:00:00 2001 From: Pip Cet Date: Wed, 3 Feb 2021 08:17:52 +0000 Subject: [PATCH] jsc/wasm32/wasm32.jsc: exit with the right status --- jsc/wasm32/wasm32.jsc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jsc/wasm32/wasm32.jsc b/jsc/wasm32/wasm32.jsc index 33ecd946..2f944367 100644 --- a/jsc/wasm32/wasm32.jsc +++ b/jsc/wasm32/wasm32.jsc @@ -5249,7 +5249,7 @@ if (typeof(os) !== "undefined" && let o = os.waitpid(pid); let output = os.file.readFile("/tmp/tmp.out." + timestamp, "binary"); let ret = this.fds[1].write(output, 0, output.length); - return this.kport.req("exit", [0]); + return this.kport.req("exit", [o.exitStatus]); } catch (e) { console.log("OH NO!"); console.log(e);