Skip to content

Create SecurityAttributes wrapper #17

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ include = ["/src/**/*", "/Cargo.toml", "/LICENSE-MIT", "/LICENSE-APACHE", "/buil

[dependencies]
winapi = { version = "0.3", features = [
"consoleapi", "errhandlingapi", "fileapi", "handleapi", "minwinbase", "minwindef", "processthreadsapi", "std", "synchapi", "unknwnbase", "winbase", "wincon", "winerror", "winnt",
"accctrl", "aclapi", "consoleapi", "errhandlingapi", "fileapi", "handleapi", "minwinbase", "minwindef", "processthreadsapi", "securitybaseapi", "std", "synchapi", "unknwnbase", "winbase", "wincon", "winerror", "winnt",
] }

[dev-dependencies]
Expand Down
2 changes: 1 addition & 1 deletion src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ use std::result;
use winapi::shared::minwindef::DWORD;
use winapi::um::errhandlingapi::GetLastError;
#[derive(Clone, Copy, Debug)]
pub struct Error(DWORD);
pub struct Error(pub(crate) DWORD);
impl Error {
pub fn code(&self) -> u32 { self.0 }
pub(crate) fn last() -> Error {
Expand Down
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ pub(crate) mod handle;
pub mod mutex;
// pub mod perf;
// pub mod pipe;
pub mod security_attributes;
// pub mod sleep;
// pub mod thread;
pub mod wide;
Expand Down
1 change: 1 addition & 0 deletions src/mutex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ use winapi::{
};
use error::Error;
use handle::Handle;
use security_attributes::SecurityAttributes;
use wide::ToWide;

pub struct SecurityAttributes(SECURITY_ATTRIBUTES);
Expand Down
Loading