Frees memory allocated by the getaddrinfo Subroutine.
The Standard C Library (<libc.a>)
#include <sys/socket.h>
#include <netdb.h>
void freeaddrinfo (struct addrinfo *ai)
The freeaddrinfo subroutine frees one or more addrinfo structures returned by the getaddrinfo subroutine, along with any additional storage associated with those structures. If the ai_next field of the structure is not NULL, the entire list of structures is freed.
Item | Description |
---|---|
ai | Points to dynamic storage allocated by the getaddrinfo subroutine |