|
|
|
@ -482,15 +482,19 @@ void _lwip_eth_rx(VirtualTap *tap, const MAC &from, const MAC &to, unsigned int |
|
|
|
int err; |
|
|
|
int err; |
|
|
|
|
|
|
|
|
|
|
|
if (Utils::ntoh(ethhdr.type) == 0x800 || Utils::ntoh(ethhdr.type) == 0x806) { |
|
|
|
if (Utils::ntoh(ethhdr.type) == 0x800 || Utils::ntoh(ethhdr.type) == 0x806) { |
|
|
|
if ((err = ((struct netif *)tap->netif4)->input(p, (struct netif *)tap->netif4)) != ERR_OK) { |
|
|
|
if (tap->netif4) { |
|
|
|
DEBUG_ERROR("packet input error (%d)", err); |
|
|
|
if ((err = ((struct netif *)tap->netif4)->input(p, (struct netif *)tap->netif4)) != ERR_OK) { |
|
|
|
pbuf_free(p); |
|
|
|
DEBUG_ERROR("packet input error (%d)", err); |
|
|
|
|
|
|
|
pbuf_free(p); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
if (Utils::ntoh(ethhdr.type) == 0x86DD) { |
|
|
|
if (Utils::ntoh(ethhdr.type) == 0x86DD) { |
|
|
|
if ((err = ((struct netif *)tap->netif6)->input(p, (struct netif *)tap->netif6)) != ERR_OK) { |
|
|
|
if (tap->netif6) { |
|
|
|
DEBUG_ERROR("packet input error (%d)", err); |
|
|
|
if ((err = ((struct netif *)tap->netif6)->input(p, (struct netif *)tap->netif6)) != ERR_OK) { |
|
|
|
pbuf_free(p); |
|
|
|
DEBUG_ERROR("packet input error (%d)", err); |
|
|
|
|
|
|
|
pbuf_free(p); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|