From 719b55cf3a458bf51cf40d7375be4924a0e3b9fc Mon Sep 17 00:00:00 2001 From: truenagual Date: Wed, 6 Sep 2017 23:09:05 +0200 Subject: [PATCH] Fixed syntax on Windows --- src/raw/windows.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/raw/windows.rs b/src/raw/windows.rs index 02eed61..7f4a8c7 100644 --- a/src/raw/windows.rs +++ b/src/raw/windows.rs @@ -131,7 +131,7 @@ pub unsafe fn open_lib(name: &OsStr) -> Result { let wide_name: Vec = name.encode_wide().chain(Some(0)).collect(); let _guard = match ErrorModeGuard::new() { Ok(val) => val, - Err(err) => return Error::OpeningLibraryError(err), + Err(err) => return Err(Error::OpeningLibraryError(err)), }; let handle = kernel32::LoadLibraryW(wide_name.as_ptr()); if handle.is_null() {