Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ rhost(3N) — GL2 W2.3

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

rsh(1C)

rlogin(1C)

socket(3N)

RHOST(3N)  —  Silicon Graphics

NAME

rhost, raddr − look up internet hosts by name or address

SYNOPSIS

iaddr = rhost(aname)
long iaddr;
char **aname; name = raddr(iaddr)
long iaddr;

DESCRIPTION

rhost uses the pointer to an Internet host name (aname) and returns the 32-bit Internet address in network byte order.  This is used as the  sockaddr_in internet address as sockaddr_in.sin_addr.s_addr.  If the host name is unknown then rhost returns −1.  If the host name is known, *aname points to the standard name of the specified host--the first name in its entry in /usr/lib/EXOS/hosts.  The return value is saved with malloc and is not destroyed on subsequent calls. 

raddr works similarly, looking up the name for an Internet address. 

FILES

/usr/lib/EXOS/hosts

SEE ALSO

rsh(1C), rlogin(1C), socket(3N)

Version 2.3  —  July 04, 1985

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026