Skip to content

Commit

Permalink
Fix clippy warning
Browse files Browse the repository at this point in the history
  • Loading branch information
sosthene-nitrokey committed Aug 2, 2023
1 parent 538923d commit 67c0952
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/lib/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -224,9 +224,7 @@ impl From<Message> for WebcryptRequest {
impl From<&[u8]> for WebcryptRequest {
fn from(arr: &[u8]) -> Self {
let mut wc_magic_number = [0u8; 4]; // FIXME correct that
for i in 0..4 {
wc_magic_number[i] = arr[1 + i];
}
wc_magic_number[..4].copy_from_slice(&arr[1..(4 + 1)]);

let mut w = WebcryptRequest {
operation_webcrypt_constant: arr[0],
Expand Down

0 comments on commit 67c0952

Please sign in to comment.