Skip to content

Commit ff31bfc

Browse files
authored
Merge pull request #407 from bytecodealliance/main
Merge bytecodealliance:main into wenyongh:main
2 parents 2cb2120 + c8fe100 commit ff31bfc

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

core/iwasm/aot/aot_runtime.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1774,7 +1774,7 @@ aot_module_malloc(AOTModuleInstance *module_inst, uint32 size,
17741774
aot_set_exception(module_inst, "app heap corrupted");
17751775
}
17761776
else {
1777-
aot_set_exception(module_inst, "out of memory");
1777+
LOG_WARNING("warning: allocate %u bytes memory failed", size);
17781778
}
17791779
return 0;
17801780
}

core/iwasm/common/wasm_shared_memory.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,8 @@ acquire_wait_info(void *address, bool create)
224224
AtomicWaitInfo *wait_info = NULL;
225225
bh_list_status ret;
226226

227-
wait_info = (AtomicWaitInfo *)bh_hash_map_find(wait_map, address);
227+
if (address)
228+
wait_info = (AtomicWaitInfo *)bh_hash_map_find(wait_map, address);
228229

229230
if (!create)
230231
return wait_info;

core/iwasm/interpreter/wasm_runtime.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1830,7 +1830,7 @@ wasm_module_malloc(WASMModuleInstance *module_inst, uint32 size,
18301830
wasm_set_exception(module_inst, "app heap corrupted");
18311831
}
18321832
else {
1833-
wasm_set_exception(module_inst, "out of memory");
1833+
LOG_WARNING("warning: allocate %u bytes memory failed", size);
18341834
}
18351835
return 0;
18361836
}

0 commit comments

Comments
 (0)