Add apis to get package version (#3601)
Add three APIs: - wasm_runtime_get_file_package_version - wasm_runtime_get_module_package_version - wasm_runtime_get_current_package_version
This commit is contained in:
@ -4168,6 +4168,8 @@ load(const uint8 *buf, uint32 size, AOTModule *module,
|
||||
return false;
|
||||
}
|
||||
|
||||
module->package_version = version;
|
||||
|
||||
if (!create_sections(module, buf, size, §ion_list, error_buf,
|
||||
error_buf_size))
|
||||
return false;
|
||||
|
||||
@ -130,6 +130,9 @@ typedef struct LocalRefFlag {
|
||||
typedef struct AOTModule {
|
||||
uint32 module_type;
|
||||
|
||||
/* the package version read from the AOT file */
|
||||
uint32 package_version;
|
||||
|
||||
/* import memories */
|
||||
uint32 import_memory_count;
|
||||
AOTImportMemory *import_memories;
|
||||
|
||||
Reference in New Issue
Block a user