The following is a list of protocol related calls:
The getprotobyname() call takes the protocol name and returns a protoent structure, which contains the name of the protocol, aliases, and protocol number. The protoent structure is defined in the <NETDB.H> header file. The getprotobynumber() call maps the protocol number into a protoent structure.
The database for these calls is provided by the ETC\PROTOCOL file.
The setprotoent(), getprotoent(), and endprotoent() calls open, provide sequential access to, and close the ETC\PROTOCOL file.