Call unload on the libraries opened

This commit is contained in:
Senthil 2016-03-24 19:20:49 -07:00
parent a1fc588316
commit d935937174
2 changed files with 6 additions and 1 deletions

View file

@ -67,6 +67,9 @@ int execute_app(
code = host_main(argc, argv);
(void)host_unload();
}
pal::unload_library(corehost);
return code;
}

View file

@ -81,7 +81,9 @@ int run(const int argc, const pal::char_t* argv[])
// Obtain entrypoint symbols
hostfxr_main_fn main_fn = (hostfxr_main_fn) pal::get_symbol(fxr, "hostfxr_main");
return main_fn(argc, argv);
int code = main_fn(argc, argv);
pal::unload_library(fxr);
return code;
}
#if defined(_WIN32)