File:  [XINU] / xinu / sys / getaddr.c
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 17:39:02 2018 UTC (8 years, 3 months ago) by root
Branches: xinu, MAIN
CVS tags: xinu-19870308, HEAD
Xinu for VAX

/* getaddr.c - getaddr */

#include <conf.h>
#include <kernel.h>
#include <network.h>

/*------------------------------------------------------------------------
 *  getaddr  -  obtain this system's complete address (IP address)
 *------------------------------------------------------------------------
 */
SYSCALL	getaddr(address)
IPaddr	address;
{
	wait (Arp.rarpsem);
	if (!Net.mavalid)
		sndrarp();
	signal(Arp.rarpsem);

	if (!Net.mavalid)
		return(SYSERR);
	blkcopy(address, Net.myaddr, IPLEN);
	return(OK);
}

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.