#!/bin/rc # # command: /bin/boddle /usr/forsyth/cd/ppp /sys/src/cmd/ppp # srcdir: /usr/forsyth/cd/ppp # version: 818223505 # date: Wed Dec 6 04:18:25 GMT 1995 # myname=$0 doextract=no fn usage{ echo $myname: usage: $myname '[-X] [src-directory]' >[1=2] exit usage } fn sigint{ rm -rf 818223505 exit interrupt } while(~ $1 -*){ switch($1){ case -X doextract=yes case -* usage } shift } switch($#*){ case 0 srcdir=/usr/forsyth/cd/ppp case 1 srcdir=$1 case * usage } if(! ~ $doextract yes){ echo This shell file contains a bundle of diffs representing changes echo to original source files in the Plan 9 distribution. It will run echo against the files in echo ' ' $srcdir echo '(unless overridden by the optional source directory argument)' echo and create a directory 818223505 containing the updated files. echo It will NOT automatically update the original files. echo echo Invoke with argument -X to perform the actual extraction. exit 0 } rm -rf 818223505 mkdir 818223505 target=818223505/compress.l echo -n '818223505/compress.l: ' if(! test -f $srcdir/compress.l || ! test -r $srcdir/compress.l){ echo $srcdir/compress.l unreadable exit unreadable } sum=`{sum < $srcdir/compress.l} if(! ~ 0aaa9ea712897 $sum(1)^$sum(2)){ echo $srcdir/compress.l is not the original distribution file exit original } cp $srcdir/compress.l 818223505/compress.l ed 818223505/compress.l >/dev/null >[2=1] <<'//GO.SYSIN DD VADIM compress.l' 526c if(s->ipcp.coptions & ILCset) . 522c if(s->ipcp.coptions & VJCset) . 218c DPRINT(2, "Bad Packet!\n"); . wq //GO.SYSIN DD VADIM compress.l sum=`{sum < 818223505/compress.l} if(~ 5077fa3212886 $sum(1)^$sum(2)) echo if not{ echo 818223505/compress.l checksum error creating updated file exit checksum } target=818223505/ppp.h echo -n '818223505/ppp.h: ' if(! test -f $srcdir/ppp.h || ! test -r $srcdir/ppp.h){ echo $srcdir/ppp.h unreadable exit unreadable } sum=`{sum < $srcdir/ppp.h} if(! ~ 354d12764220 $sum(1)^$sum(2)){ echo $srcdir/ppp.h is not the original distribution file exit original } cp $srcdir/ppp.h 818223505/ppp.h ed 818223505/ppp.h >/dev/null >[2=1] <<'//GO.SYSIN DD VADIM ppp.h' 198a extern int useilc; . 196c #define DPRINT if(debug)fprint . 182a uint ilcmask(uint); . 179c void ipconfig(byte*, byte*, int); . 29a VJCset = 1<<0, ILCset = 1<<1, . wq //GO.SYSIN DD VADIM ppp.h sum=`{sum < 818223505/ppp.h} if(~ 97fec0e14299 $sum(1)^$sum(2)) echo if not{ echo 818223505/ppp.h checksum error creating updated file exit checksum } target=818223505/ppp.l echo -n '818223505/ppp.l: ' if(! test -f $srcdir/ppp.l || ! test -r $srcdir/ppp.l){ echo $srcdir/ppp.l unreadable exit unreadable } sum=`{sum < $srcdir/ppp.l} if(! ~ 3089502017618 $sum(1)^$sum(2)){ echo $srcdir/ppp.l is not the original distribution file exit original } cp $srcdir/ppp.l 818223505/ppp.l ed 818223505/ppp.l >/dev/null >[2=1] <<'//GO.SYSIN DD VADIM ppp.l' 812c DPRINT(2, "IPCONFIG: %s\n", cmd); . 809,810c sprint(cmd, "setip %d.%d.%d.%d %d.%d.%d.%d", myip[0], myip[1], myip[2], myip[3], myipmask[0], myipmask[1], myipmask[2], myipmask[3]); . 798c ipconfig(byte *myip, byte *myipmask, int server) . 762c DPRINT(2, "Got a note %s\n", c); . 736a uint ilcmask(uint cfg) { switch(cfg) { case VJCompression: return VJCset; case ILCompression: return ILCset; default: return 0; } } . 712c DPRINT(2, "Starting fd %d peerip %d.%d.%d.%d\n", . 624c DPRINT(2, "IPCP layer is in state %s\n", statestr[s->ipcp.state]); . 616c DPRINT(2, "LCP layer is in state %s\n", statestr[s->lcp.state]); . 591c DPRINT(2, "Got a packet in prtcl %lux size %d\n", protocol, ndata); . 356c DPRINT(2, "Configure NAK\n"); . 303c DPRINT(2, "received an NCP(%ux) packet %d\n", ncp->prtcl, cpkt->code); . 279,280c } else { ncp->coptions &= ~ilcmask(nhgets(cfr->data)); fprint(2, "coptions: %x\n", ncp->coptions); } . 276c DPRINT(2, "Peer says my IP address is %d.%d.%d.%d\n", . 214c ncp->coptions |= ilcmask(nhgets(v->prtcl)); fprint(2, "coptions: %x\n", ncp->coptions); . 205c DPRINT(2, "Peer wants to do compress %x %d %d\n", . 199c return Rej; /* was Nak */ . 197c DPRINT(2, "Peer wants to learn his ip address\n"); . 180a DPRINT(2, "reject lcp config type %d\n", cfr->cfrtype); . 125c if(useilc && ncp->options & (1 << IPCompressionPrtcl)) { . 42c DPRINT(2, "sending prtcl %ux request code %d\n", ncp->prtcl, code); . 16a int useilc=0; . wq //GO.SYSIN DD VADIM ppp.l sum=`{sum < 818223505/ppp.l} if(~ 70c1bb9818082 $sum(1)^$sum(2)) echo if not{ echo 818223505/ppp.l checksum error creating updated file exit checksum } target=818223505/pppclient.l echo -n '818223505/pppclient.l: ' if(! test -f $srcdir/pppclient.l || ! test -r $srcdir/pppclient.l){ echo $srcdir/pppclient.l unreadable exit unreadable } sum=`{sum < $srcdir/pppclient.l} if(! ~ 25ca37292454 $sum(1)^$sum(2)){ echo $srcdir/pppclient.l is not the original distribution file exit original } cp $srcdir/pppclient.l 818223505/pppclient.l ed 818223505/pppclient.l >/dev/null >[2=1] <<'//GO.SYSIN DD VADIM pppclient.l' 140c ipconfig(s.ipcp.myipaddr, myipmask, 0); . 119a case 'm': parseip(myipmask, argv[opt++]); break; case '9': ++useilc; break; . 105a myipmask[0] = myipmask[1] = myipmask[2] = 255; myipmask[3] = 0; . 100c byte myipaddr[4], peeripaddr[4], myipmask[4]; . 85c DPRINT(2, "Send Size = %d\n", n); . 32c fatal("usage: ppp [-d] [-9] [-b] [-i myipaddr] [-p peeripaddr] [-m myipmask] [dialstring]"); . wq //GO.SYSIN DD VADIM pppclient.l sum=`{sum < 818223505/pppclient.l} if(~ 8fcd3eda2656 $sum(1)^$sum(2)) echo if not{ echo 818223505/pppclient.l checksum error creating updated file exit checksum } target=818223505/pppserver.l echo -n '818223505/pppserver.l: ' if(! test -f $srcdir/pppserver.l || ! test -r $srcdir/pppserver.l){ echo $srcdir/pppserver.l unreadable exit unreadable } sum=`{sum < $srcdir/pppserver.l} if(! ~ 30daea282548 $sum(1)^$sum(2)){ echo $srcdir/pppserver.l is not the original distribution file exit original } cp $srcdir/pppserver.l 818223505/pppserver.l ed 818223505/pppserver.l >/dev/null >[2=1] <<'//GO.SYSIN DD VADIM pppserver.l' 140c ipconfig(myipaddr, ipmask, 1); . 114a case 'm': parseip(ipmask, argv[opt++]); break; . 109a ipmask[0] = ipmask[1] = ipmask[2] = 255; ipmask[3] = 0; . 108c byte baseipaddr[4], myipaddr[4], ipmask[4], str[150]; . 93c DPRINT(2, "Send Size = %d\n", n); . 69c fatal("usage: pppserver [-d] [-m ipmask] nlines myip baseip baseseriallineno (baudratelist)"); . wq //GO.SYSIN DD VADIM pppserver.l sum=`{sum < 818223505/pppserver.l} if(~ dbda4ade2694 $sum(1)^$sum(2)) echo if not{ echo 818223505/pppserver.l checksum error creating updated file exit checksum }