1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-07-29 05:21:37 +03:00

emulation on host: fix incorrect lwIP DNS implementation (#8627)

* emulation on host: fix incorrect lwIP DNS implementation
+initialize netif0, make ipv6 example unfail
This commit is contained in:
david gauchard
2022-07-09 12:36:35 +02:00
committed by GitHub
parent a8e3786d38
commit 00f5f2acc4
2 changed files with 23 additions and 21 deletions

View File

@ -3,6 +3,8 @@
#include "MocklwIP.h"
#include <lwip/dns.h>
esp8266::AddressListImplementation::AddressList addrList;
extern "C"
@ -57,4 +59,18 @@ extern "C"
return &netif0;
}
void dns_setserver(u8_t numdns, const ip_addr_t* dnsserver)
{
(void)numdns;
(void)dnsserver;
}
const ip_addr_t* dns_getserver(u8_t numdns)
{
(void)numdns;
static ip_addr_t addr;
IP4_ADDR(&addr, 127, 0, 0, 1);
return &addr;
}
} // extern "C"