Merge pull request #110 from oliverschmidt/master
Removed uiplib_ip6addrconv() from IPv4 builds.
This commit is contained in:
commit
47a8462e54
|
@ -41,6 +41,7 @@
|
|||
#include "net/uip-debug.h"
|
||||
|
||||
/*-----------------------------------------------------------------------------------*/
|
||||
#if UIP_CONF_IPV6
|
||||
int
|
||||
uiplib_ip6addrconv(const char *addrstr, uip_ip6addr_t *ipaddr)
|
||||
{
|
||||
|
@ -102,6 +103,7 @@ uiplib_ip6addrconv(const char *addrstr, uip_ip6addr_t *ipaddr)
|
|||
|
||||
return 1;
|
||||
}
|
||||
#endif /* UIP_CONF_IPV6 */
|
||||
/*-----------------------------------------------------------------------------------*/
|
||||
/* Parse a IPv4-address from a string. Returns the number of characters read
|
||||
* for the address. */
|
||||
|
@ -139,14 +141,3 @@ uiplib_ip4addrconv(const char *addrstr, uip_ip4addr_t *ipaddr)
|
|||
return charsread-1;
|
||||
}
|
||||
/*-----------------------------------------------------------------------------------*/
|
||||
int
|
||||
uiplib_ipaddrconv(const char *addrstr, uip_ipaddr_t *ipaddr)
|
||||
{
|
||||
#if UIP_CONF_IPV6
|
||||
return uiplib_ip6addrconv(addrstr, ipaddr);
|
||||
#else /* UIP_CONF_IPV6 */
|
||||
return uiplib_ip4addrconv(addrstr, ipaddr);
|
||||
#endif /* UIP_CONF_IPV6 */
|
||||
}
|
||||
|
||||
/*-----------------------------------------------------------------------------------*/
|
||||
|
|
|
@ -66,7 +66,11 @@
|
|||
* \retval 0 If the IP address could not be parsed.
|
||||
* \retval Non-zero If the IP address was parsed.
|
||||
*/
|
||||
CCIF int uiplib_ipaddrconv(const char *addrstr, uip_ipaddr_t *addr);
|
||||
#if UIP_CONF_IPV6
|
||||
#define uiplib_ipaddrconv uiplib_ip6addrconv
|
||||
#else /* UIP_CONF_IPV6 */
|
||||
#define uiplib_ipaddrconv uiplib_ip4addrconv
|
||||
#endif /* UIP_CONF_IPV6 */
|
||||
|
||||
CCIF int uiplib_ip4addrconv(const char *addrstr, uip_ip4addr_t *addr);
|
||||
CCIF int uiplib_ip6addrconv(const char *addrstr, uip_ip6addr_t *addr);
|
||||
|
|
Loading…
Reference in a new issue