Explorar o código

Fix assert with any_ip + broadcast dst_addr. Fixes #533

Dario Nieuwenhuis %!s(int64=3) %!d(string=hai) anos
pai
achega
21e0a30d64
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      src/iface/interface.rs

+ 1 - 0
src/iface/interface.rs

@@ -1239,6 +1239,7 @@ impl<'a> InterfaceInner<'a> {
             // Ignore IP packets not directed at us, or broadcast, or any of the multicast groups.
             // If AnyIP is enabled, also check if the packet is routed locally.
             if !self.any_ip
+                || !ipv4_repr.dst_addr.is_unicast()
                 || self
                     .routes
                     .lookup(&IpAddress::Ipv4(ipv4_repr.dst_addr), cx.now)