Fixed macro ip_addr_set_loopback(): htonl was missing (fixes bug #28828: ip_addr.h some macro error)

This commit is contained in:
goldsimon 2010-02-08 12:25:01 +00:00
parent 6c027c153b
commit 47756a8faa

View File

@ -136,7 +136,7 @@ extern const ip_addr_t ip_addr_broadcast;
/** Set complete address to zero */
#define ip_addr_set_zero(ipaddr) (ipaddr)->addr = IPADDR_ANY
/** Set address to loopback address */
#define ip_addr_set_loopback(ipaddr) ((ipaddr)->addr = IPADDR_LOOPBACK)
#define ip_addr_set_loopback(ipaddr) ((ipaddr)->addr = htonl(IPADDR_LOOPBACK))
/** Safely copy one IP address to another and change byte order
* from host- to network-order. */
#define ip_addr_set_hton(dest, src) ((dest)->addr = \