From 50381fb40bfa58d9e07d1b68dcdb7577688532cf Mon Sep 17 00:00:00 2001 From: Simon Bihel Date: Wed, 23 Aug 2023 15:44:29 +0100 Subject: [PATCH] Remove unnecessary mut in examples --- README.md | 2 +- src/lib.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 1593777..0f0c589 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ Session pool manager for [cryptoki](https://github.com/parallaxsecond/rust-crypt ```rust no_run use r2d2_cryptoki::{*, cryptoki::{context::*, types::AuthPin}}; -let mut pkcs11 = Pkcs11::new("libsofthsm2.so").unwrap(); +let pkcs11 = Pkcs11::new("libsofthsm2.so").unwrap(); pkcs11.initialize(CInitializeArgs::OsThreads).unwrap(); let slots = pkcs11.get_slots_with_token().unwrap(); let slot = slots.first().unwrap(); diff --git a/src/lib.rs b/src/lib.rs index deaca22..23131ea 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -57,7 +57,7 @@ impl SessionManager { /// # Example /// ```no_run /// # use r2d2_cryptoki::{*, cryptoki::{context::*, types::AuthPin}}; - /// let mut pkcs11 = Pkcs11::new("libsofthsm2.so").unwrap(); + /// let pkcs11 = Pkcs11::new("libsofthsm2.so").unwrap(); /// pkcs11 .initialize(CInitializeArgs::OsThreads).unwrap(); /// let slots = pkcs11.get_slots_with_token().unwrap(); /// let slot = slots.first().unwrap(); @@ -79,7 +79,7 @@ impl SessionManager { /// # Example /// ```no_run /// # use r2d2_cryptoki::{*, cryptoki::{context::*, types::AuthPin}}; - /// # let mut pkcs11 = Pkcs11::new("libsofthsm2.so").unwrap(); + /// # let pkcs11 = Pkcs11::new("libsofthsm2.so").unwrap(); /// # pkcs11.initialize(CInitializeArgs::OsThreads); /// # let slots = pkcs11.get_slots_with_token().unwrap(); /// # let slot = slots.first().unwrap();