MCPcopy Create free account
hub / github.com/Recordscript/recordscript / uninit

Method uninit

libs/scrap/src/dxgi/mag.rs:207–226  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

205 }
206
207 pub(super) fn uninit(&mut self) {
208 if self.init_succeeded {
209 if let Some(uninit_func) = self.mag_uninitialize_func {
210 unsafe {
211 if FALSE == uninit_func() {
212 println!("Failed MagUninitialize, error {}", Error::last_os_error())
213 }
214 }
215 }
216 if !self.lib_handle.is_null() {
217 unsafe {
218 if FALSE == FreeLibrary(self.lib_handle) {
219 println!("Failed FreeLibrary, error {}", Error::last_os_error())
220 }
221 }
222 self.lib_handle = NULL as _;
223 }
224 }
225 self.init_succeeded = false;
226 }
227}
228
229impl Drop for MagInterface {

Callers 1

dropMethod · 0.80

Calls 1

is_nullMethod · 0.45

Tested by

no test coverage detected