diff options
author | Eduardo Broto <ebroto@tutanota.com> | 2019-12-07 21:24:57 +0100 |
---|---|---|
committer | Eduardo Broto <ebroto@tutanota.com> | 2019-12-07 22:38:01 +0100 |
commit | 9e6f390c1f34de0d0b413f4704fc2d1f655c47bc (patch) | |
tree | 089b711721a9c4aac2e461a2fa7211d7ba5de266 /src/main.rs | |
parent | 423c6a52ba84c27b8667a762ee33bc28f44f0e37 (diff) |
chore(style): fix clippy errors
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main.rs b/src/main.rs index b4d46cf..9022cfa 100644 --- a/src/main.rs +++ b/src/main.rs @@ -11,6 +11,7 @@ use network::{ dns::{self, IpTable}, Connection, Sniffer, Utilization, }; +use os::OnSigWinch; use ::pnet::datalink::{DataLinkReceiver, NetworkInterface}; use ::std::collections::HashMap; @@ -82,12 +83,12 @@ pub struct OsInputOutput { pub get_open_sockets: fn() -> HashMap<Connection, String>, pub keyboard_events: Box<dyn Iterator<Item = Event> + Send>, pub dns_client: Option<dns::Client>, - pub on_winch: Box<dyn Fn(Box<dyn Fn()>) + Send>, + pub on_winch: Box<OnSigWinch>, pub cleanup: Box<dyn Fn() + Send>, pub write_to_stdout: Box<dyn FnMut(String) + Send>, } -pub fn start<'a, B>(terminal_backend: B, os_input: OsInputOutput, opts: Opt) +pub fn start<B>(terminal_backend: B, os_input: OsInputOutput, opts: Opt) where B: Backend + Send + 'static, { @@ -132,7 +133,6 @@ where .spawn({ let running = running.clone(); let network_utilization = network_utilization.clone(); - let ui = ui.clone(); move || { while running.load(Ordering::Acquire) { let render_start_time = Instant::now(); |