History | View | Annotate | Download (3.4 kB)
slirp/arp_table.c: Avoid shifting into sign bit of signed integers
"0xf << 28" shifts right into the sign bit, since 0xf is a signedinteger. Use the 'U' suffix to force an unsigned shift to avoidthis undefined behaviour and a clang sanitizer warning.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>...
slirp: Don't crash on packets from 0.0.0.0/8.
LWIP can generate packets with a source of 0.0.0.0, which triggers anassertion failure in arp_table_add(). Instead of crashing, simply returnto avoid adding an invalid ARP table entry.
Signed-off-by: Nickolai Zeldovich <nickolai@csail.mit.edu>...
slirp: Fix types of IP address parameters
Should be uint32_t for IPv4, not int. Also avoid in_addr_t withoutproper includes. Fixes build regression on mingw32.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Simple ARP table
This patch adds a simple ARP table in Slirp and also adds handling ofgratuitous ARP requests.
Signed-off-by: Fabien Chouteau <chouteau@adacore.com>Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>