From 1f508ddfb69e4bdedbb7fa3ba7034f8938eacbd9 Mon Sep 17 00:00:00 2001 From: Brooks J Rady Date: Sun, 27 Dec 2020 00:17:15 +0000 Subject: Convince clippy to chill --- src/os/shared.rs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/os/shared.rs') diff --git a/src/os/shared.rs b/src/os/shared.rs index 4ef25a9..ae42022 100644 --- a/src/os/shared.rs +++ b/src/os/shared.rs @@ -35,9 +35,11 @@ impl Iterator for TerminalEvents { pub(crate) fn get_datalink_channel( interface: &NetworkInterface, ) -> Result, GetInterfaceErrorKind> { - let mut config = Config::default(); - config.read_timeout = Some(time::Duration::new(1, 0)); - config.read_buffer_size = 65536; + let config = Config { + read_timeout: Some(time::Duration::new(1, 0)), + read_buffer_size: 65536, + ..Default::default() + }; match datalink::channel(interface, config) { Ok(Ethernet(_tx, rx)) => Ok(rx), -- cgit v1.2.3