Function windows_win::raw::module::get_module_handle_from_addr
source · pub fn get_module_handle_from_addr(module_addr: LPCWSTR) -> Result<HMODULE>
Expand description
Retrieves module handle by using address inside.
Underhood it uses flags GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS | GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT
Due to that produced HMODULE must not be passed to FreeLibrary
Use macro module_to_addr!
to convert local function into module address.