Parcourir la source

Don't terminate other threads when create thread failed (#1955)

Xu Jun il y a 3 ans
Parent
commit
531771eb11
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 2 2
      core/iwasm/libraries/thread-mgr/thread_manager.c

+ 2 - 2
core/iwasm/libraries/thread-mgr/thread_manager.c

@@ -484,7 +484,7 @@ fail4:
     /* free the allocated aux stack space */
     /* free the allocated aux stack space */
     free_aux_stack(cluster, aux_stack_start);
     free_aux_stack(cluster, aux_stack_start);
 fail3:
 fail3:
-    wasm_exec_env_destroy(new_exec_env);
+    wasm_exec_env_destroy_internal(new_exec_env);
 fail2:
 fail2:
     wasm_runtime_deinstantiate_internal(new_module_inst, true);
     wasm_runtime_deinstantiate_internal(new_module_inst, true);
 fail1:
 fail1:
@@ -605,7 +605,7 @@ fail3:
     /* free the allocated aux stack space */
     /* free the allocated aux stack space */
     free_aux_stack(cluster, aux_stack_start);
     free_aux_stack(cluster, aux_stack_start);
 fail2:
 fail2:
-    wasm_exec_env_destroy(new_exec_env);
+    wasm_exec_env_destroy_internal(new_exec_env);
 fail1:
 fail1:
     os_mutex_unlock(&cluster->lock);
     os_mutex_unlock(&cluster->lock);