Revert "Return error when exception was raised after main thread finishes" (#2524)

This reverts commit 71d43f3ca1.
This commit is contained in:
YAMAMOTO Takashi 2023-09-04 19:01:09 +09:00 committed by GitHub
parent 2e78230e06
commit 9e3904337e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 2 additions and 13 deletions

View File

@ -921,12 +921,8 @@ main(int argc, char *argv[])
#if WASM_ENABLE_LIBC_WASI != 0
if (ret == 0) {
/* wait for threads to finish and propagate wasi exit code. */
/* propagate wasi exit code. */
ret = wasm_runtime_get_wasi_exit_code(wasm_module_inst);
if (wasm_runtime_get_exception(wasm_module_inst)) {
/* got an exception in spawned thread */
ret = 1;
}
}
#endif

View File

@ -554,12 +554,8 @@ main(int argc, char *argv[])
#if WASM_ENABLE_LIBC_WASI != 0
if (ret == 0) {
/* wait for threads to finish and propagate wasi exit code. */
/* propagate wasi exit code. */
ret = wasm_runtime_get_wasi_exit_code(wasm_module_inst);
if (wasm_runtime_get_exception(wasm_module_inst)) {
/* got an exception in spawned thread */
ret = 1;
}
}
#endif