Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site down.UUCP Path: utzoo!linus!philabs!seismo!harpo!eagle!mh3bs!mhtsa!exodus!gamma!ulysses!princeton!down!honey From: honey@down.UUCP Newsgroups: net.sources Subject: Re: Pathalias Sources Message-ID: <27@down.UUCP> Date: Sat, 21-Jan-84 13:10:55 EST Article-I.D.: down.27 Posted: Sat Jan 21 13:10:55 1984 Date-Received: Sun, 22-Jan-84 07:46:18 EST References: <202@sjuvax.UUCP> Organization: Princeton Univ. EECS Lines: 117 here are some minor mods i have made. there's a variable that should be declared a static. i added a -n flag to request supression of network names, so that only site names are put in the database. i increased the size of the site name buffer from 16 to 32 bytes; bbn-minet-gateway is a site in my arpa list. diff -c output follows. peter honeyman *** addhop.c Sat Jan 21 11:52:17 1984 --- ../../addhop.c Fri Jun 3 13:56:16 1983 *************** *** 79,85 register hop *h; static char *nb = NULL, *nb2; char indbuf[5], *tnb; ! int j, nbl; register int i; if (nb == NULL) { --- 79,86 ----- register hop *h; static char *nb = NULL, *nb2; char indbuf[5], *tnb; ! int j; ! static int nbl; register int i; if (nb == NULL) { *** def.h Sat Jan 21 11:52:29 1984 --- ../../def.h Wed Jun 1 11:49:37 1983 *************** *** 7,13 #define QPATH 64 /* Quanta of path structures to malloc at once */ #define QHOP 8 /* Number of hops per path structure */ #define NHASH 73 /* number of hash table indices */ ! #define NAMELEN 16 #define isnetc(c) ((c)=='!' || (c)=='.' || (c)==':' || (c)=='^' || \ (c)=='@' || (c)=='%') --- 7,13 ----- #define QPATH 64 /* Quanta of path structures to malloc at once */ #define QHOP 8 /* Number of hops per path structure */ #define NHASH 73 /* number of hash table indices */ ! #define NAMELEN 32 /* down!honey -- for **long** arpa sites */ #define isnetc(c) ((c)=='!' || (c)=='.' || (c)==':' || (c)=='^' || \ (c)=='@' || (c)=='%') *************** *** 96,98 extern int oneflag; extern int nwarnflag; extern int ncostflag; --- 95,98 ----- extern int oneflag; extern int nwarnflag; extern int ncostflag; + extern int netflag; *** main.c Sat Jan 21 11:52:40 1984 --- ../../main.c Sat Jan 21 12:18:18 1984 *************** *** 15,20 int oneflag; int nwarnflag; int ncostflag; main(argc, argv) int argc; char *argv[]; { --- 15,21 ----- int oneflag; int nwarnflag; int ncostflag; + int netflag; /* down!honey -- don't print network names */ main(argc, argv) int argc; char *argv[]; { *************** *** 40,45 break; case 'w': nwarnflag++; break; #ifdef DBM case 'b': --- 41,49 ----- break; case 'w': nwarnflag++; + break; + case 'n': + netflag++; break; #ifdef DBM case 'b': *** dumpmap.c Sat Jan 21 11:52:32 1984 --- ../../dumpmap.c Sat Jan 21 12:46:42 1984 *************** *** 27,32 ; for (i--; i >= ncount; i--) { n = all[i]; npath = pathname(n->n_path); #ifdef DBM if (dbflag) wdb(n, npath); --- 27,34 ----- ; for (i--; i >= ncount; i--) { n = all[i]; + if (netflag && (n->n_flag & NNET)) + continue; npath = pathname(n->n_path); #ifdef DBM if (dbflag) wdb(n, npath);