Mercurial > crates > nonstick
diff src/conv.rs @ 64:bbe84835d6db v0.0.5
More organization; add lots of docs.
- moves `PamHandle` to its own module, since it will be used
by both modules and clients.
- adds a ton of documentation to the `PamModule` trait
and reorders methods to most-interesting-first.
- adds more flag values from pam_modules.h.
- other misc cleanup.
author | Paul Fisher <paul@pfish.zone> |
---|---|
date | Thu, 22 May 2025 01:52:32 -0400 |
parents | a7aa5ca0d00d |
children |
line wrap: on
line diff
--- a/src/conv.rs Wed May 21 23:19:43 2025 -0400 +++ b/src/conv.rs Thu May 22 01:52:32 2025 -0400 @@ -3,14 +3,14 @@ //! This module is experimental and will probably be rewritten in the future //! to improve the interface for both PAM modules and clients. +use crate::constants::MessageStyle; +use crate::constants::Result; +use crate::constants::{ErrorCode, InvalidEnum}; +use crate::items::Item; use libc::{c_char, c_int}; +use num_derive::FromPrimitive; use std::ffi::{CStr, CString}; use std::ptr; -use num_derive::FromPrimitive; -use crate::constants::{ErrorCode, InvalidEnum}; -use crate::constants::MessageStyle; -use crate::constants::Result; -use crate::items::Item; /// Styles of message that are shown to the user. #[derive(Debug, PartialEq, FromPrimitive)] @@ -44,7 +44,6 @@ } } - #[repr(C)] struct Message { msg_style: MessageStyle,