Enlarge max pool size and fix bh_memcpy_s dest max size check (#1151)
Enlarge max pool size and fix bh_memcpy_s dest max size check to support large linear memory, e.g. with initial page count 65535.
This commit is contained in:
@ -86,7 +86,7 @@ wasm_runtime_memory_pool_size()
|
||||
if (memory_mode == MEMORY_MODE_POOL)
|
||||
return global_pool_size;
|
||||
else
|
||||
return 1 * BH_GB;
|
||||
return UINT32_MAX;
|
||||
}
|
||||
|
||||
static inline void *
|
||||
|
||||
@ -20,6 +20,9 @@ wasm_runtime_memory_init(mem_alloc_type_t mem_alloc_type,
|
||||
void
|
||||
wasm_runtime_memory_destroy();
|
||||
|
||||
unsigned
|
||||
wasm_runtime_memory_pool_size();
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user