Compare commits

..

No commits in common. "cfffb62ad2cbe217dd7ec122a3b7a16aac236997" and "4c2af25aff9de6df2c23083840f1ff783e7ebbcb" have entirely different histories.

View File

@ -660,18 +660,15 @@ load_native_symbol_section(const uint8 *buf, const uint8 *buf_end,
read_uint32(p, p_end, cnt);
if (cnt > 0) {
uint64 list_size = cnt * (uint64)sizeof(void *);
module->native_symbol_list =
loader_malloc(list_size, error_buf, error_buf_size);
module->native_symbol_list = wasm_runtime_malloc(cnt * sizeof(void *));
if (module->native_symbol_list == NULL) {
set_error_buf(error_buf, error_buf_size,
"malloc native symbol list failed");
goto fail;
}
for (i = cnt - 1; i >= 0; i--) {
read_string(p, p_end, symbol);
if (!strlen(symbol))
continue;
if (!strncmp(symbol, "f32#", 4) || !strncmp(symbol, "i32#", 4)) {
uint32 u32;
/* Resolve the raw int bits of f32 const */
@ -2170,9 +2167,6 @@ load_globals(const uint8 **p_buf, const uint8 *buf_end, AOTModule *module,
read_uint8(buf, buf_end, globals[i].type.val_type);
read_uint8(buf, buf_end, globals[i].type.is_mutable);
if (!is_valid_value_type(globals[i].type.val_type))
return false;
buf = align_ptr(buf, 4);
if (!load_init_expr(&buf, buf_end, module, &globals[i].init_expr,