re-org platform APIs, simplify porting process (#201)
Co-authored-by: Xu Jun <jun1.xu@intel.com>
This commit is contained in:
@ -29,10 +29,8 @@ app_instance_main(wasm_module_inst_t module_inst)
|
||||
|
||||
extern "C" {
|
||||
|
||||
int bh_printf(const char *message, ...);
|
||||
|
||||
typedef void (*bh_print_function_t)(const char* message);
|
||||
extern void bh_set_print_function(bh_print_function_t pf);
|
||||
typedef void (*os_print_function_t)(const char* message);
|
||||
extern void os_set_print_function(os_print_function_t pf);
|
||||
|
||||
void enclave_print(const char *message)
|
||||
{
|
||||
@ -43,7 +41,7 @@ void enclave_print(const char *message)
|
||||
|
||||
void ecall_iwasm_main()
|
||||
{
|
||||
bh_set_print_function(enclave_print);
|
||||
os_set_print_function(enclave_print);
|
||||
|
||||
uint8_t *wasm_file_buf = NULL;
|
||||
int wasm_file_size;
|
||||
|
||||
Reference in New Issue
Block a user