From bc99d9d196e3da89192f43a2ada042fe357e9371 Mon Sep 17 00:00:00 2001 From: "B. Petersen" Date: Thu, 10 Oct 2019 00:39:35 +0200 Subject: [PATCH] cargo fmt --- mmime/src/other.rs | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/mmime/src/other.rs b/mmime/src/other.rs index 19ebbfdd3..40f295764 100644 --- a/mmime/src/other.rs +++ b/mmime/src/other.rs @@ -40,14 +40,8 @@ pub(crate) unsafe fn strncasecmp( // s1 and s2 might not be null terminated. - let s1_slice = std::slice::from_raw_parts( - s1 as *const u8, - strnlen(s1 as *const i8, n), - ); - let s2_slice = std::slice::from_raw_parts( - s2 as *const u8, - strnlen(s2 as *const i8, n), - ); + let s1_slice = std::slice::from_raw_parts(s1 as *const u8, strnlen(s1 as *const i8, n)); + let s2_slice = std::slice::from_raw_parts(s2 as *const u8, strnlen(s2 as *const i8, n)); let s1 = std::ffi::CStr::from_bytes_with_nul_unchecked(s1_slice) .to_string_lossy()