HP-UX IPv6 Porting Guide (February 2007)

Identifying Local Interface Names and Indexes
Freeing Memory
Chapter 1250
The if_nameindex() function acquires memory dynamically for the array of if_nameindex
structures and for if_name’s interface names. The if_freenameindex() function frees that
memory.
Freeing Memory
The if_freenameindex() function frees the dynamic-memory allocated by if_nameindex().
Header Files
#include <net/if.h>
Syntax
void if_freenameindex(struct if_nameindex *ptr);
The ptr parameter is the pointer returned by a previous if_nameindex() call.