]> git.ipfire.org Git - people/ms/suricata.git/blobdiff - rust/src/smb/smb2.rs
rust(lint): use let for binding single value
[people/ms/suricata.git] / rust / src / smb / smb2.rs
index 115facdf4a7dc026dd31f1c5e9282d7207aba60b..756c69081d484f716960429b5aeb2200b36d533e 100644 (file)
@@ -168,9 +168,7 @@ pub fn smb2_read_response_record<'b>(state: &mut SMBState, r: &Smb2Record<'b>)
                     _ => { (Vec::new(), false) },
                 };
                 let mut is_dcerpc = if is_pipe || (share_name.len() == 0 && !is_pipe) {
-                    match state.get_service_for_guid(&file_guid) {
-                        (_, x) => x,
-                    }
+                    state.get_service_for_guid(&file_guid).1
                 } else {
                     false
                 };
@@ -280,9 +278,7 @@ pub fn smb2_write_request_record<'b>(state: &mut SMBState, r: &Smb2Record<'b>)
                     _ => { (Vec::new(), false) },
                 };
                 let mut is_dcerpc = if is_pipe || (share_name.len() == 0 && !is_pipe) {
-                    match state.get_service_for_guid(wr.guid) {
-                        (_, x) => x,
-                    }
+                    state.get_service_for_guid(wr.guid).1
                 } else {
                     false
                 };