mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-10-05 22:29:49 +00:00
dns: fixed declaration and usage of DNS_LOOKUP_LOCAL_EXTERN()
This commit is contained in:
parent
7e3de89646
commit
811b237bd7
@ -616,7 +616,7 @@ dns_lookup(const char *name, ip_addr_t *addr LWIP_DNS_ADDRTYPE_ARG(u8_t dns_addr
|
|||||||
}
|
}
|
||||||
#endif /* DNS_LOCAL_HOSTLIST */
|
#endif /* DNS_LOCAL_HOSTLIST */
|
||||||
#ifdef DNS_LOOKUP_LOCAL_EXTERN
|
#ifdef DNS_LOOKUP_LOCAL_EXTERN
|
||||||
if (DNS_LOOKUP_LOCAL_EXTERN(name, addr, LWIP_DNS_ADDRTYPE_ARG_OR_ZERO(dns_addrtype))) {
|
if (DNS_LOOKUP_LOCAL_EXTERN(name, addr, LWIP_DNS_ADDRTYPE_ARG_OR_ZERO(dns_addrtype)) == ERR_OK) {
|
||||||
return ERR_OK;
|
return ERR_OK;
|
||||||
}
|
}
|
||||||
#endif /* DNS_LOOKUP_LOCAL_EXTERN */
|
#endif /* DNS_LOOKUP_LOCAL_EXTERN */
|
||||||
|
@ -884,8 +884,8 @@
|
|||||||
* byte order).
|
* byte order).
|
||||||
*
|
*
|
||||||
* Instead, you can also use an external function:
|
* Instead, you can also use an external function:
|
||||||
* \#define DNS_LOOKUP_LOCAL_EXTERN(x) extern u32_t my_lookup_function(const char *name)
|
* \#define DNS_LOOKUP_LOCAL_EXTERN(x) extern err_t my_lookup_function(const char *name, ip_addr_t *addr, u8_t dns_addrtype)
|
||||||
* that returns the IP address or INADDR_NONE if not found.
|
* that looks up the IP address and returns ERR_OK if found (LWIP_DNS_ADDRTYPE_* is passed in dns_addrtype).
|
||||||
*/
|
*/
|
||||||
#ifndef DNS_LOCAL_HOSTLIST
|
#ifndef DNS_LOCAL_HOSTLIST
|
||||||
#define DNS_LOCAL_HOSTLIST 0
|
#define DNS_LOCAL_HOSTLIST 0
|
||||||
|
Loading…
Reference in New Issue
Block a user