diff --git a/CHANGELOG b/CHANGELOG index 65b33d2d..263d19e7 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -321,6 +321,9 @@ HISTORY ++ Bugfixes: + 2016-07-19: Simon Goldschmidt + * etharp.c: fixed bug #48477 (ARP input packet might update static entry) + 2016-07-11: Simon Goldschmidt * tcp_in.c: fixed bug #48476 (TCP sent callback called wrongly due to picking up old pcb->acked diff --git a/src/core/ipv4/etharp.c b/src/core/ipv4/etharp.c index 28d33cc8..5481d3bd 100644 --- a/src/core/ipv4/etharp.c +++ b/src/core/ipv4/etharp.c @@ -480,6 +480,9 @@ etharp_update_arp_entry(struct netif *netif, const ip4_addr_t *ipaddr, struct et if (flags & ETHARP_FLAG_STATIC_ENTRY) { /* record static type */ arp_table[i].state = ETHARP_STATE_STATIC; + } else if (arp_table[i].state == ETHARP_STATE_STATIC) { + /* found entry is a static type, don't overwrite it */ + return ERR_VAL; } else #endif /* ETHARP_SUPPORT_STATIC_ENTRIES */ {