Fix a typo in 5c3fc493.

v0.7.x
whitequark 2017-06-27 21:51:56 +00:00
parent 04bd8a0051
commit 6ad8fea31f
1 changed files with 1 additions and 1 deletions

View File

@ -193,7 +193,7 @@ impl<'a, 'b, 'c, DeviceT: Device + 'a> Interface<'a, 'b, 'c, DeviceT> {
let ipv4_packet = Ipv4Packet::new_checked(eth_frame.payload())?;
let ipv4_repr = Ipv4Repr::parse(&ipv4_packet)?;
if ipv4_repr.src_addr.is_unicast() {
if !ipv4_repr.src_addr.is_unicast() {
// Discard packets with non-unicast source addresses.
return Err(Error::Malformed)
}