From 7412c028921bc6bf211bb519275ab3599f715990 Mon Sep 17 00:00:00 2001 From: Jack Grigg Date: Thu, 21 Nov 2019 13:12:46 +0000 Subject: [PATCH] Remove dead code from internals --- src/internal.rs | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/src/internal.rs b/src/internal.rs index e6cee67..dff7b60 100644 --- a/src/internal.rs +++ b/src/internal.rs @@ -30,8 +30,7 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// TODO(tarcieri): investigate and remove dead code -#![allow(non_upper_case_globals, dead_code)] +#![allow(non_upper_case_globals)] #![allow(clippy::missing_safety_doc)] use crate::consts::*; @@ -51,10 +50,6 @@ impl DesKey { pub fn from_bytes(bytes: [u8; DES_LEN_3DES]) -> Self { DesKey(bytes) } - - pub fn write(&self, out: &mut [u8]) { - out.copy_from_slice(&self.0); - } } impl AsRef<[u8; 24]> for DesKey { @@ -150,17 +145,6 @@ pub fn yk_des_is_weak_key(key: &[u8; DES_LEN_3DES]) -> bool { rv } -/// PKCS#5 error types -#[derive(Clone, Copy, Debug, Eq, PartialEq)] -#[repr(i32)] -pub enum Pkcs5ErrorKind { - /// OK - Ok = 0, - - /// General error - GeneralError = -1, -} - /// Source of how a setting was configured #[derive(Clone, Copy, Debug, Eq, PartialEq)] pub enum SettingSource {