Add at_init emscripten_environ_constructor

This commit is contained in:
Brandon Fish 2019-02-06 00:11:31 -06:00
parent b86acab3e4
commit 2b55606d3c

View File

@ -140,6 +140,10 @@ pub fn run_emscripten_instance(
let data_ptr = &mut data as *mut _ as *mut c_void;
instance.context_mut().data = data_ptr;
if let Ok(_func) = instance.dyn_func("___emscripten_environ_constructor") {
instance.call("___emscripten_environ_constructor", &[])?;
}
let main_func = instance.dyn_func("_main")?;
let num_params = main_func.signature().params().len();
let _result = match num_params {