Open System Services Porting Guide (G06.29+, H06.06+, J06.03+)

Table 14 Additional Internet Domain Support Functions (continued)
DescriptionFunction
Gets the protocol number of the specified protocol namegetprotobyname()
Gets the protocol name of the specified protocol numbergetprotobynumber()
Gets the service port number for the specified port namegetservbyname()
Gets the service name of the specified port numbergetservbyport()
Gets the name of the host with the specified Internet addresshost_file_gethostbyaddr()
Gets the Internet address of the specified hosthost_file_gethostbyname()
Frees dynamic memory allocated by the if_nameindex functionif_freenameindex()
Maps an interface index to its corresponding nameif_indextoname()
Gets all interface names and indexesif_nameindex()
Maps an interface name to its corresponding indexif_nametoindex()
Converts an Internet address from dotted-decimal format to binary formatinet_addr()
Breaks apart an Internet address and returns the local or host number portioninet_lnaof()
Combines a network address and local address into an Internet addressinet_makeaddr()
Breaks apart an Internet address and returns the network portioninet_netof()
Converts an Internet address from dotted-decimal format and returns the network
address portion in integer format
inet_network()
Converts an Internet address from binary to dotted-decimal formatinet_ntoa()
Converts a binary internet address to a character stringinet_ntop()
Converts a character string to an IPv6 or IPv4 binary addressinet_pton()
Unless nowait (nonblocking) sockets input/output is used, you can sometimes structure a Guardian
application with feature test macros such that it can be recompiled without semantic changes for
execution in the OSS environment.
Interoperability of OSS and Guardian Sockets in an OSS Application 185