Skip to main content

free_library

Function free_library 

Source
pub fn free_library(module_handle: isize) -> usize
Expand description

Frees the loaded dll. The function expects the module’s base address.

If the function succeeds, the return value is nonzero.

§Examples

let module_handle: usize = dyncvoke_core::load_library_a("somedll.dll");
let ret = dyncvoke_core::free_library(module_handle as isize);

if ret == 0 {println!("somedll.dll sucessfully freed.")};