disable broadcasting

This commit is contained in:
griffi-gh 2023-02-06 02:41:34 +01:00
parent 324dc5d43e
commit b940a9d9d6

View file

@ -17,7 +17,7 @@ impl Server {
pub fn bind(addr: SocketAddr) -> anyhow::Result<Self> { pub fn bind(addr: SocketAddr) -> anyhow::Result<Self> {
let socket = UdpSocket::bind(addr)?; let socket = UdpSocket::bind(addr)?;
socket.set_nonblocking(true)?; socket.set_nonblocking(true)?;
socket.set_broadcast(true)?; //socket.set_broadcast(true)?;
Ok(Self { Ok(Self {
socket, socket,
clients: HashMap::with_capacity_and_hasher(MAX_CLIENTS, BuildNoHashHasher::default()) clients: HashMap::with_capacity_and_hasher(MAX_CLIENTS, BuildNoHashHasher::default())