September 2001
Intermediate to advanced
768 pages
32h 45m
English
mixed getprotobynumber(int port_number) Gets the protocol name for a protocol number.
Returns:
Name of the protocol; FALSE on error
Description:
getprotobynumber() gets the protocol name for the given protocol number on the local system. If the protocol number is not recognized, the function returns FALSE. If you’re looking for port-to-service mapping (that is, port 80 is HTTP), see getservbyport().
Information on the protocol names and corresponding numbers can be found in RFC 1340 and your system’s /etc/protocol or c:\windows\protocol file (if present).
Availability:
UNIX, Windows
Version:
4.0b4+
See also:
getprotobyname()
Example:
Read now
Unlock full access