|
CX Framework
Cross-platform C utility framework
|
#include <net_shared.h>
Data Fields | |
| NetAddrType | type |
| Address type (NA_IPv4, NA_IPv6) | |
| uint32 | scope |
| Scope ID (for IPv6) | |
| uint16 | port |
| Port number. | |
Network address structure
Byte order differs by field:
port and scope are host byte order, ordinary integers.ipv4 is host order too: ipv4[0] is the least significant octet, so all four bytes can be treated together as a uint32.ipv6 is stored in network order exactly as it travels on the wire, ipv6[0] first – IPv6 addresses are just a 16-byte identifier with no meaningful "host order". Definition at line 283 of file net_shared.h.