netof.c revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* Copyright (c) 1996 by Sun Microsystems, Inc.
* All Rights Reserved.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
/*
* netof - return the net address part of an ip address
* (zero out host part)
*/
#include <stdio.h>
#include "ntp_fp.h"
#include "ntp_stdlib.h"
{
netnum &= IN_CLASSC_NET;
netnum &= IN_CLASSB_NET;
else /* treat all other like class A */
netnum &= IN_CLASSA_NET;
return netnum;
}