diff --git a/src/main.rs b/src/main.rs index f86891c..768bfc4 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,5 +1,5 @@ use chrono::{DateTime, Duration, Local}; -use std::{collections::HashMap, net::UdpSocket}; +use std::{collections::HashMap, net::UdpSocket, thread}; use log::debug; const MAX_CLIENTS: usize = 10; @@ -135,6 +135,8 @@ fn main() -> std::io::Result<()> { let speed = buf[1] >> 2; let data = &buf[0..number_of_bytes]; + thread::sleep(core::time::Duration::from_millis(200)); // Anti floog (?) + if receivers2.contains_key(&client_addr) { debug!("Client known: {client_addr}"); if strip_header(data) == strip_header(mopp(speed, b":bye").as_slice()) {