1: /*
   2:  * Copyright (c) 1983 Regents of the University of California.
   3:  * All rights reserved.  The Berkeley software License Agreement
   4:  * specifies the terms and conditions for redistribution.
   5:  *
   6:  *	@(#)defs.h	5.5 (Berkeley) 2/14/86";
   7:  */
   8: 
   9: #include <sys/types.h>
  10: #include <sys/socket.h>
  11: 
  12: #include <net/route.h>
  13: #include <netns/ns.h>
  14: #include <netns/idp.h>
  15: #if defined(vax) || defined(pdp11)
  16: #define xnnet(x) ((u_long) (x)->rip_dst[1] << 16 | (u_long) (x)->rip_dst[0] )
  17: #else
  18: #define xnnet(x) ((u_long) (x)->rip_dst[0] << 16 | (u_long) (x)->rip_dst[1] )
  19: #endif
  20: #define IDPPORT_RIF 1
  21: 
  22: #include <stdio.h>
  23: #include <syslog.h>
  24: 
  25: #include "protocol.h"
  26: #include "trace.h"
  27: #include "interface.h"
  28: #include "table.h"
  29: #include "af.h"
  30: 
  31: 
  32: /*
  33:  * When we find any interfaces marked down we rescan the
  34:  * kernel every CHECK_INTERVAL seconds to see if they've
  35:  * come up.
  36:  */
  37: #define CHECK_INTERVAL  (5*60)
  38: 
  39: #define equal(a1, a2) \
  40:     (bcmp((caddr_t)(a1), (caddr_t)(a2), sizeof (struct sockaddr)) == 0)
  41: #define min(a,b)    ((a)>(b)?(b):(a))
  42: 
  43: struct  sockaddr_ns addr;   /* Daemon's Address */
  44: int s;          /* Socket to listen on */
  45: int kmem;
  46: int supplier;       /* process should supply updates */
  47: int install;        /* if 1 call kernel */
  48: int lookforinterfaces;  /* if 1 probe kernel for new up interfaces */
  49: int performnlist;       /* if 1 check if /vmunix has changed */
  50: int externalinterfaces; /* # of remote and local interfaces */
  51: int timeval;        /* local idea of time */
  52: int noteremoterequests; /* squawk on requests from non-local nets */
  53: 
  54: char    packet[MAXPACKETSIZE+sizeof(struct idp)+1];
  55: struct  rip *msg;
  56: 
  57: char    **argv0;
  58: 
  59: extern  char *sys_errlist[];
  60: extern  int errno;
  61: 
  62: char    *malloc();
  63: int exit();
  64: int sendmsg();
  65: int supply();
  66: int timer();
  67: int cleanup();

Defined variables

addr defined in line 43; used 32 times
argv0 defined in line 57; used 2 times
externalinterfaces defined in line 50; used 2 times
install defined in line 47; used 3 times
kmem defined in line 45; never used
noteremoterequests defined in line 52; used 2 times
packet defined in line 54; used 5 times
performnlist defined in line 49; never used
s defined in line 44; used 37 times
supplier defined in line 46; used 12 times
timeval defined in line 51; used 3 times

Defined macros

CHECK_INTERVAL defined in line 37; used 1 times
IDPPORT_RIF defined in line 20; used 3 times
equal defined in line 39; used 4 times
xnnet defined in line 18; never used

Usage of this include

Last modified: 1986-02-15
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 1167
Valid CSS Valid XHTML 1.0 Strict