1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

pkg/lwip: fix sending from socket bound to anyaddr

This commit is contained in:
Marian Buschsieweke 2022-07-22 09:38:51 +02:00
parent f590c18f7f
commit d646a71e71
No known key found for this signature in database
GPG Key ID: CB8E3238CE715A94

View File

@ -641,7 +641,8 @@ ssize_t lwip_sock_sendv(struct netconn *conn, const iolist_t *snips,
DEBUG("\"\n");
}
uint16_t netif = lwip_sock_bind_addr_to_netif(&addr);
if (remote->netif != netif) {
if ((remote->netif != netif)
&& (netif != SOCK_ADDR_ANY_NETIF)) {
DEBUG("[lwip_sock_sendv] lwip_sock_bind_addr_to_netif() "
"returned %u, but expected %u\n",
(unsigned)netif, (unsigned)remote->netif);