Struct libcryptsetup_rs::SafeBorrowedMemZero
source · pub struct SafeBorrowedMemZero(/* private fields */);
Expand description
Handle for zeroing borrowed memory. “Borrowed” in this context refers to memory
that will be cleaned up by some other scope and is not required to be freed
by the caller. An example of this would be a char *
pointer to kernel memory
where the caller can access the memory but is not responsible for its
allocation or deallocation.
Implementations§
Trait Implementations§
source§impl AsMut<[u8]> for SafeBorrowedMemZero
impl AsMut<[u8]> for SafeBorrowedMemZero
source§impl AsRef<[u8]> for SafeBorrowedMemZero
impl AsRef<[u8]> for SafeBorrowedMemZero
source§impl Drop for SafeBorrowedMemZero
impl Drop for SafeBorrowedMemZero
source§impl SafeMemzero for SafeBorrowedMemZero
impl SafeMemzero for SafeBorrowedMemZero
source§fn safe_memzero(&mut self)
fn safe_memzero(&mut self)
Zero the data in the buffer. To enable managed zeroing of a buffer,
call this in a
Drop
implementation.Auto Trait Implementations§
impl Freeze for SafeBorrowedMemZero
impl RefUnwindSafe for SafeBorrowedMemZero
impl !Send for SafeBorrowedMemZero
impl !Sync for SafeBorrowedMemZero
impl Unpin for SafeBorrowedMemZero
impl UnwindSafe for SafeBorrowedMemZero
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more