Fix clippy complaints

This commit is contained in:
cyqsimon
2023-10-11 18:25:40 +08:00
parent 94ada5db8a
commit 3703c676f2

View File

@@ -72,15 +72,15 @@ impl DataLinkReceiver for NetworkFrames {
if self.current_index < self.packets.len() {
let action = self.next_packet();
match action {
Some(packet) => Ok(&packet[..]),
Some(packet) => Ok(packet),
None => {
thread::sleep(time::Duration::from_secs(1));
Ok(&[][..])
Ok(&[])
}
}
} else {
thread::sleep(time::Duration::from_secs(1));
Ok(&[][..])
Ok(&[])
}
}
}