diff --git a/src/netif/etharp.c b/src/netif/etharp.c index 9183b847..613a323f 100644 --- a/src/netif/etharp.c +++ b/src/netif/etharp.c @@ -1279,7 +1279,9 @@ ethernet_input(struct pbuf *p, struct netif *netif) { struct eth_hdr* ethhdr; u16_t type; +#if LWIP_ARP || ETHARP_SUPPORT_VLAN s16_t ip_hdr_offset = SIZEOF_ETH_HDR; +#endif /* LWIP_ARP || ETHARP_SUPPORT_VLAN */ if (p->len <= SIZEOF_ETH_HDR) { /* a packet with only an ethernet header (or less) is not valid for us */