lwall@jato.Jpl.Nasa.Gov (Larry Wall) (09/16/89)
Apply these to a virgin perl 3.0 beta directory to produce a perl 3.0 gamma directory. Recommended patch switches are -p1 -N. Larry Wall lwall@jpl-devvax.jpl.nasa.gov diff -c -r beta/perl.y gamma/perl.y *** beta/perl.y Fri Sep 15 16:06:26 1989 --- gamma/perl.y Fri Sep 15 16:10:57 1989 *************** *** 584,590 **** { $$ = make_op(O_SHIFT, 1, $3, Nullarg, Nullarg); } | SHIFT %prec '(' { $$ = make_op(O_SHIFT, 1, ! stab2arg(A_STAB,aadd(stabent("ARGV",TRUE))), Nullarg, Nullarg); } | SPLIT %prec '(' { (void)scanpat("/\\s+/"); --- 584,591 ---- { $$ = make_op(O_SHIFT, 1, $3, Nullarg, Nullarg); } | SHIFT %prec '(' { $$ = make_op(O_SHIFT, 1, ! stab2arg(A_STAB, ! aadd(stabent(subline ? "_" : "ARGV", TRUE))), Nullarg, Nullarg); } | SPLIT %prec '(' { (void)scanpat("/\\s+/"); diff -c -r beta/perly.c gamma/perly.c *** beta/perly.c Fri Sep 15 16:07:08 1989 --- gamma/perly.c Fri Sep 15 16:11:25 1989 *************** *** 1,4 **** ! char rcsid[] = "$Header: perly.c,v 3.0 beta$\nPatch level: ###\n"; /* * Copyright (c) 1989, Larry Wall * --- 1,4 ---- ! char rcsid[] = "$Header: perly.c,v 3.0 gamma$\nPatch level: ###\n"; /* * Copyright (c) 1989, Larry Wall * *************** *** 57,63 **** goto just_doit; } (void)sprintf(index(rcsid,'#'), "%d\n", PATCHLEVEL); ! linestr = str_new(80); str_nset(linestr,"",0); str = str_make("",0); /* first used for -I flags */ curstash = defstash = hnew(0); --- 57,63 ---- goto just_doit; } (void)sprintf(index(rcsid,'#'), "%d\n", PATCHLEVEL); ! linestr = Str_new(65,80); str_nset(linestr,"",0); str = str_make("",0); /* first used for -I flags */ curstash = defstash = hnew(0); *************** *** 585,591 **** stab_io(tmpstab)->ofp = stab_io(tmpstab)->ifp = stderr; stab_io(stabent("stderr",TRUE)) = stab_io(tmpstab); ! statname = str_new(0); /* last filename we did stat on */ perldb = FALSE; /* don't try to instrument evals */ --- 585,591 ---- stab_io(tmpstab)->ofp = stab_io(tmpstab)->ifp = stderr; stab_io(stabent("stderr",TRUE)) = stab_io(tmpstab); ! statname = Str_new(66,0); /* last filename we did stat on */ perldb = FALSE; /* don't try to instrument evals */ *************** *** 719,725 **** (void)sprintf(buf,"%s/%s",str_get(afetch(ar,i,TRUE)),filename); rsfp = fopen(buf,"r"); if (rsfp) { - free(filename); filename = savestr(buf); break; } --- 719,724 ---- diff -c -r beta/regcomp.h gamma/regcomp.h *** beta/regcomp.h Fri Sep 15 16:07:35 1989 --- gamma/regcomp.h Fri Sep 15 16:12:09 1989 *************** *** 125,131 **** * Using two bytes for the "next" pointer is vast overkill for most things, * but allows patterns to get big without disasters. * ! * [If ALIGN is defined, the "next" pointer is always aligned on an even * boundary, and reads the offset directly as a short. Also, there is no * special test to reverse the sign of BACK pointers since the offset is * stored negative.] --- 125,131 ---- * Using two bytes for the "next" pointer is vast overkill for most things, * but allows patterns to get big without disasters. * ! * [If REGALIGN is defined, the "next" pointer is always aligned on an even * boundary, and reads the offset directly as a short. Also, there is no * special test to reverse the sign of BACK pointers since the offset is * stored negative.] diff -c -r beta/stab.c gamma/stab.c *** beta/stab.c Fri Sep 15 16:06:03 1989 --- gamma/stab.c Fri Sep 15 16:10:42 1989 *************** *** 225,231 **** stab->str_len = stab->str_cur = sizeof(STBP); stab->str_pok = 1; strncpy(stab_magic(stab),"Stab",4); ! stab_val(stab) = str_new(0); stab_line(stab) = line; } else --- 225,231 ---- stab->str_len = stab->str_cur = sizeof(STBP); stab->str_pok = 1; strncpy(stab_magic(stab),"Stab",4); ! stab_val(stab) = Str_new(70,0); stab_line(stab) = line; } else *************** *** 420,426 **** savearray = stab_xarray(defstab); stab_xarray(defstab) = stack = anew(defstab); stack->ary_flags = 0; ! str = str_new(0); str_set(str,sig_name[sig]); (void)apush(stab_xarray(defstab),str); sub->depth++; --- 420,426 ---- savearray = stab_xarray(defstab); stab_xarray(defstab) = stack = anew(defstab); stack->ary_flags = 0; ! str = Str_new(71,0); str_set(str,sig_name[sig]); (void)apush(stab_xarray(defstab),str); sub->depth++; *************** *** 547,553 **** stab->str_len = stab->str_cur = sizeof(STBP); stab->str_pok = 1; strncpy(stab_magic(stab),"Stab",4); ! stab_val(stab) = str_new(0); stab_line(stab) = line; str_magic(stab,stab,'*',name,len); return stab; --- 547,553 ---- stab->str_len = stab->str_cur = sizeof(STBP); stab->str_pok = 1; strncpy(stab_magic(stab),"Stab",4); ! stab_val(stab) = Str_new(72,0); stab_line(stab) = line; str_magic(stab,stab,'*',name,len); return stab; diff -c -r beta/stab.h gamma/stab.h *** beta/stab.h Fri Sep 15 16:07:52 1989 --- gamma/stab.h Fri Sep 15 16:12:31 1989 *************** *** 45,50 **** --- 45,53 ---- struct stio { FILE *ifp; /* ifp and ofp are normally the same */ FILE *ofp; /* but sockets need separate streams */ + #if defined(I_DIRENT) || defined(I_SYSDIR) + DIR *dirp; /* for opendir, readdir, etc */ + #endif long lines; /* $. */ long page; /* $% */ long page_len; /* $= */ diff -c -r beta/str.c gamma/str.c *** beta/str.c Fri Sep 15 16:06:55 1989 --- gamma/str.c Fri Sep 15 16:11:32 1989 *************** *** 311,317 **** --- 311,322 ---- } STR * + #ifdef LEAKTEST + str_new(x,len) + int x; + #else str_new(len) + #endif int len; { register STR *str; *************** *** 323,329 **** str->str_state = SS_NORM; } else { ! Newz(701,str,1,STR); } if (len) STR_GROW(str, len + 1); --- 328,334 ---- str->str_state = SS_NORM; } else { ! Newz(700+x,str,1,STR); } if (len) STR_GROW(str, len + 1); *************** *** 340,346 **** { if (str->str_magic) return; ! str->str_magic = str_new(namlen); str = str->str_magic; str->str_u.str_stab = stab; str->str_rare = how; --- 345,351 ---- { if (str->str_magic) return; ! str->str_magic = Str_new(75,namlen); str = str->str_magic; str->str_u.str_stab = stab; str->str_rare = how; *************** *** 470,475 **** --- 475,487 ---- } if (str->str_magic) str_free(str->str_magic); + #ifdef LEAKTEST + if (str->str_len) + Safefree(str->str_ptr); + if ((str->str_pok & SP_INTRP) && str->str_u.str_args) + arg_free(str->str_u.str_args); + Safefree(str); + #else /* LEAKTEST */ if (str->str_len) { if (str->str_len > 127) { /* next user not likely to want more */ Safefree(str->str_ptr); /* so give it back to malloc */ *************** *** 490,495 **** --- 502,508 ---- #endif str->str_magic = freestrroot; freestrroot = str; + #endif /* LEAKTEST */ } str_len(str) *************** *** 542,553 **** (void)str_2ptr(str2); if (str1->str_cur < str2->str_cur) { ! if (retval = bcmp(str1->str_ptr, str2->str_ptr, str1->str_cur)) return retval; else return 1; } ! else if (retval = bcmp(str1->str_ptr, str2->str_ptr, str2->str_cur)) return retval; else if (str1->str_cur == str2->str_cur) return 0; --- 555,566 ---- (void)str_2ptr(str2); if (str1->str_cur < str2->str_cur) { ! if (retval = memcmp(str1->str_ptr, str2->str_ptr, str1->str_cur)) return retval; else return 1; } ! else if (retval = memcmp(str1->str_ptr, str2->str_ptr, str2->str_cur)) return retval; else if (str1->str_cur == str2->str_cur) return 0; *************** *** 627,636 **** #else /* !STDSTDIO */ /* The big, slow, and stupid way */ ! static char buf[4192]; ! if (fgets(buf, sizeof buf, fp) != Nullch) ! str_set(str, buf); else str_set(str, No); --- 640,653 ---- #else /* !STDSTDIO */ /* The big, slow, and stupid way */ ! static char buf[8192]; ! if (fgets(buf, sizeof buf, fp) != Nullch) { ! if (append) ! str_cat(str, buf); ! else ! str_set(str, buf); ! } else str_set(str, No); *************** *** 684,691 **** register int brackets; STAB *stab; ! toparse = str_new(0); ! str = str_new(0); str_nset(str,"",0); str_nset(toparse,"",0); --- 701,708 ---- register int brackets; STAB *stab; ! toparse = Str_new(76,0); ! str = Str_new(77,0); str_nset(str,"",0); str_nset(toparse,"",0); *************** *** 887,898 **** * hopefully cmd_exec won't free it until it has been assigned to a * permanent location. */ STR * str_static(oldstr) STR *oldstr; { ! register STR *str = str_new(0); ! static long tmps_size = -1; str_sset(str,oldstr); if (++tmps_max > tmps_size) { --- 904,916 ---- * hopefully cmd_exec won't free it until it has been assigned to a * permanent location. */ + static long tmps_size = -1; + STR * str_static(oldstr) STR *oldstr; { ! register STR *str = Str_new(78,0); str_sset(str,oldstr); if (++tmps_max > tmps_size) { *************** *** 908,919 **** return str; } STR * str_make(s,len) char *s; int len; { ! register STR *str = str_new(0); if (!len) len = strlen(s); --- 926,956 ---- return str; } + /* same thing without the copying */ + STR * + str_2static(str) + register STR *str; + { + if (++tmps_max > tmps_size) { + tmps_size = tmps_max; + if (!(tmps_size & 127)) { + if (tmps_size) + Renew(tmps_list, tmps_size + 128, STR*); + else + New(704,tmps_list, 128, STR*); + } + } + tmps_list[tmps_max] = str; + return str; + } + + STR * str_make(s,len) char *s; int len; { ! register STR *str = Str_new(79,0); if (!len) len = strlen(s); *************** *** 925,931 **** str_nmake(n) double n; { ! register STR *str = str_new(0); str_numset(str,n); return str; --- 962,968 ---- str_nmake(n) double n; { ! register STR *str = Str_new(80,0); str_numset(str,n); return str; *************** *** 937,943 **** str_smake(old) register STR *old; { ! register STR *new = str_new(0); if (!old) return Nullstr; --- 974,980 ---- str_smake(old) register STR *old; { ! register STR *new = Str_new(81,0); if (!old) return Nullstr; diff -c -r beta/str.h gamma/str.h *** beta/str.h Fri Sep 15 16:07:44 1989 --- gamma/str.h Fri Sep 15 16:12:21 1989 *************** *** 113,118 **** --- 113,119 ---- char *str_2ptr(); double str_2num(); STR *str_static(); + STR *str_2static(); STR *str_make(); STR *str_nmake(); STR *str_smake(); Common subdirectories: beta/t and gamma/t diff -c -r beta/toke.c gamma/toke.c *** beta/toke.c Fri Sep 15 16:05:44 1989 --- gamma/toke.c Fri Sep 15 16:10:14 1989 *************** *** 130,136 **** } oldoldbufptr = oldbufptr = bufptr = s; if (perldb) { ! STR *str = str_new(0); str_sset(str,linestr); astore(lineary,(int)line,str); --- 130,136 ---- } oldoldbufptr = oldbufptr = bufptr = s; if (perldb) { ! STR *str = Str_new(85,0); str_sset(str,linestr); astore(lineary,(int)line,str); *************** *** 429,434 **** --- 429,436 ---- UNI(O_CHDIR); if (strEQ(d,"close")) FOP(O_CLOSE); + if (strEQ(d,"closedir")) + FOP(O_CLOSEDIR); if (strEQ(d,"crypt")) { #ifdef FCRYPT init_des(); *************** *** 503,508 **** --- 505,514 ---- FUN0(O_ESERVENT); if (strEQ(d,"endprotoent")) FUN0(O_EPROTOENT); + if (strEQ(d,"endpwent")) + FUN0(O_EPWENT); + if (strEQ(d,"endgrent")) + FUN0(O_EGRENT); break; case 'f': case 'F': SNARFWORD; *************** *** 557,562 **** --- 563,576 ---- FUN1(O_GPBYNUMBER); if (strEQ(d,"protoent")) FUN0(O_GPROTOENT); + if (strEQ(d,"pwent")) + FUN0(O_GPWENT); + if (strEQ(d,"pwnam")) + FUN1(O_GPWNAM); + if (strEQ(d,"pwuid")) + FUN1(O_GPWUID); + if (strEQ(d,"peername")) + FOP(O_GETPEERNAME); } else if (*d == 'h') { if (strEQ(d,"hostbyname")) *************** *** 581,587 **** --- 595,617 ---- FUN2(O_GSBYPORT); if (strEQ(d,"servent")) FUN0(O_GSERVENT); + if (strEQ(d,"sockname")) + FOP(O_GETSOCKNAME); + if (strEQ(d,"sockopt")) + FOP3(O_GSOCKOPT); } + else if (*d == 'g') { + if (strEQ(d,"grent")) + FUN0(O_GGRENT); + if (strEQ(d,"grnam")) + FUN1(O_GGRNAM); + if (strEQ(d,"grgid")) + FUN1(O_GGRGID); + } + else if (*d == 'l') { + if (strEQ(d,"login")) + FUN0(O_GETLOGIN); + } d -= 3; } break; *************** *** 635,640 **** --- 665,672 ---- FUN2(O_LINK); if (strEQ(d,"listen")) FOP2(O_LISTEN); + if (strEQ(d,"lstat")) + FOP(O_LSTAT); break; case 'm': case 'M': SNARFWORD; *************** *** 660,665 **** --- 692,699 ---- UNI(O_ORD); if (strEQ(d,"oct")) UNI(O_OCT); + if (strEQ(d,"opendir")) + FOP2(O_OPENDIR); break; case 'p': case 'P': SNARFWORD; *************** *** 711,716 **** --- 745,754 ---- FUN2(O_RINDEX); if (strEQ(d,"read")) FOP3(O_READ); + if (strEQ(d,"readdir")) + FOP(O_READDIR); + if (strEQ(d,"rewinddir")) + FOP(O_REWINDDIR); if (strEQ(d,"recv")) FOP4(O_RECV); if (strEQ(d,"reverse")) *************** *** 749,754 **** --- 787,800 ---- FUN1(O_SSERVENT); if (strEQ(d,"setprotoent")) FUN1(O_SPROTOENT); + if (strEQ(d,"setpwent")) + FUN0(O_SPWENT); + if (strEQ(d,"setgrent")) + FUN0(O_SGRENT); + if (strEQ(d,"seekdir")) + FOP2(O_SEEKDIR); + if (strEQ(d,"setsockopt")) + FOP4(O_SSOCKOPT); break; case 'f': case 'g': *************** *** 756,761 **** --- 802,809 ---- case 'h': if (strEQ(d,"shift")) TERM(SHIFT); + if (strEQ(d,"shutdown")) + FOP2(O_SHUTDOWN); break; case 'i': if (strEQ(d,"sin")) *************** *** 851,856 **** --- 899,906 ---- } if (strEQ(d,"symlink")) FUN2(O_SYMLINK); + if (strEQ(d,"syscall")) + LOP(O_SYSCALL); break; case 'z': break; *************** *** 864,869 **** --- 914,921 ---- } if (strEQ(d,"tell")) FOP(O_TELL); + if (strEQ(d,"telldir")) + FOP(O_TELLDIR); if (strEQ(d,"time")) FUN0(O_TIME); if (strEQ(d,"times")) *************** *** 912,918 **** OPERATOR(WHILE); } if (strEQ(d,"warn")) ! UNI(O_WARN); if (strEQ(d,"wait")) FUN0(O_WAIT); if (strEQ(d,"wantarray")) --- 964,970 ---- OPERATOR(WHILE); } if (strEQ(d,"warn")) ! LOP(O_WARN); if (strEQ(d,"wait")) FUN0(O_WAIT); if (strEQ(d,"wantarray")) *************** *** 1014,1020 **** if (index(string,'|')) { return Nullstr; } ! retstr = str_new(len); str_nset(retstr,string,len); t = str_get(retstr); e = t + len; --- 1066,1072 ---- if (index(string,'|')) { return Nullstr; } ! retstr = Str_new(86,len); str_nset(retstr,string,len); t = str_get(retstr); e = t + len; *************** *** 1278,1284 **** spat->spat_repl = fixeval(make_op(O_EVAL,2, spat->spat_repl, Nullarg, ! Nullarg,0)); spat->spat_flags &= ~SPAT_CONST; } if (*s == 'g') { --- 1330,1336 ---- spat->spat_repl = fixeval(make_op(O_EVAL,2, spat->spat_repl, Nullarg, ! Nullarg)); spat->spat_flags &= ~SPAT_CONST; } if (*s == 'g') { *************** *** 1369,1375 **** register char *s; { ARG *arg = ! l(make_op(O_TRANS,2,stab2arg(A_STAB,defstab),Nullarg,Nullarg,0)); register char *t; register char *r; register char *tbl; --- 1421,1427 ---- register char *s; { ARG *arg = ! l(make_op(O_TRANS,2,stab2arg(A_STAB,defstab),Nullarg,Nullarg)); register char *t; register char *r; register char *tbl; *************** *** 1634,1640 **** term = tmps[5]; multi_close = term; } ! tmpstr = str_new(0); if (hereis) { term = *tokenbuf; if (!rsfp) { --- 1686,1692 ---- term = tmps[5]; multi_close = term; } ! tmpstr = Str_new(87,0); if (hereis) { term = *tokenbuf; if (!rsfp) { *************** *** 1667,1673 **** } line++; if (perldb) { ! STR *str = str_new(0); str_sset(str,linestr); astore(lineary,(int)line,str); --- 1719,1725 ---- } line++; if (perldb) { ! STR *str = Str_new(88,0); str_sset(str,linestr); astore(lineary,(int)line,str); *************** *** 1805,1811 **** while ((s = str_gets(linestr,rsfp, 0)) != Nullch) { line++; if (perldb) { ! STR *tmpstr = str_new(0); str_sset(tmpstr,linestr); astore(lineary,(int)line,tmpstr); --- 1857,1863 ---- while ((s = str_gets(linestr,rsfp, 0)) != Nullch) { line++; if (perldb) { ! STR *tmpstr = Str_new(89,0); str_sset(tmpstr,linestr); astore(lineary,(int)line,tmpstr); *************** *** 1878,1884 **** goto badform; line++; if (perldb) { ! STR *tmpstr = str_new(0); str_sset(tmpstr,linestr); astore(lineary,(int)line,tmpstr); --- 1930,1936 ---- goto badform; line++; if (perldb) { ! STR *tmpstr = Str_new(90,0); str_sset(tmpstr,linestr); astore(lineary,(int)line,tmpstr); *************** *** 1891,1897 **** if (*s == '#') goto again; bufend = linestr->str_ptr + linestr->str_cur; ! str = flinebeg->f_unparsed = str_new(bufend - bufptr); str->str_u.str_hash = curstash; str_nset(str,"(",1); flinebeg->f_line = line; --- 1943,1949 ---- if (*s == '#') goto again; bufend = linestr->str_ptr + linestr->str_cur; ! str = flinebeg->f_unparsed = Str_new(91,bufend - bufptr); str->str_u.str_hash = curstash; str_nset(str,"(",1); flinebeg->f_line = line; *************** *** 1937,1944 **** default: yyerror("Please use commas to separate fields"); } - str_ncat(str,"$$);",4); } } } } --- 1989,1996 ---- default: yyerror("Please use commas to separate fields"); } } + str_ncat(str,"$$);",4); } } } diff -c -r beta/util.c gamma/util.c *** beta/util.c Fri Sep 15 16:07:02 1989 --- gamma/util.c Fri Sep 15 16:11:37 1989 *************** *** 11,18 **** #include "EXTERN.h" #include "perl.h" #include "errno.h" ! #ifdef VARARGS # include <varargs.h> #endif --- 11,23 ---- #include "EXTERN.h" #include "perl.h" #include "errno.h" + #include <signal.h> ! #ifdef sparc ! # include <vfork.h> ! #endif ! ! #ifdef I_VARARGS # include <varargs.h> #endif *************** *** 100,105 **** --- 105,111 ---- /* safe version of free */ + void safefree(where) char *where; { *************** *** 117,122 **** --- 123,182 ---- } } + #ifdef LEAKTEST + + #define ALIGN sizeof(long) + + char * + safexmalloc(x,size) + int x; + MEM_SIZE size; + { + register char *where; + + where = safemalloc(size + ALIGN); + xcount[x]++; + where[0] = x % 100; + where[1] = x / 100; + return where + ALIGN; + } + + char * + safexrealloc(where,size) + char *where; + MEM_SIZE size; + { + return saferealloc(where - ALIGN, size + ALIGN) + ALIGN; + } + + void + safexfree(where) + char *where; + { + int x; + + if (!where) + return; + where -= ALIGN; + x = where[0] + 100 * where[1]; + xcount[x]--; + safefree(where); + } + + xstat() + { + register int i; + + for (i = 0; i < MAXXCOUNT; i++) { + if (xcount[i] != lastxcount[i]) { + fprintf(stderr,"%2d %2d\t%ld\n", i / 100, i % 100, xcount[i]); + lastxcount[i] = xcount[i]; + } + } + } + + #endif /* LEAKTEST */ + /* copy a string up to some (non-backslashed) delimiter, if any */ char * *************** *** 681,686 **** --- 741,752 ---- { mess(pat,a1,a2,a3,a4); fputs(buf,stderr); + #ifdef LEAKTEST + #ifdef DEBUGGING + if (debug & 4096) + xstat(); + #endif + #endif (void)fflush(stderr); } #else *************** *** 690,696 **** { char *pat; char *s; ! #ifdef CHARSPRINTF char *vsprintf(); #else int vsprintf(); --- 756,762 ---- { char *pat; char *s; ! #ifdef CHARVSPRINTF char *vsprintf(); #else int vsprintf(); *************** *** 765,770 **** --- 831,842 ---- va_end(args); fputs(buf,stderr); + #ifdef LEAKTEST + #ifdef DEBUGGING + if (debug & 4096) + xstat(); + #endif + #endif (void)fflush(stderr); } #endif *************** *** 862,868 **** #ifdef VARARGS #ifndef VPRINTF ! #ifdef CHARSPRINTF char * #else int --- 934,940 ---- #ifdef VARARGS #ifndef VPRINTF ! #ifdef CHARVSPRINTF char * #else int *************** *** 877,883 **** --- 949,959 ---- fakebuf._flag = _IOWRT|_IOSTRG; _doprnt(pat, args, &fakebuf); /* what a kludge */ (void)putc('\0', &fakebuf); + #ifdef CHARVSPRINTF return(dest); + #else + return 0; /* perl doesn't use return value */ + #endif } #ifdef DEBUGGING *************** *** 988,993 **** --- 1064,1070 ---- if (pipe(p) < 0) return Nullfp; this = (*mode == 'w'); + that = !this; while ((pid = (doexec?vfork():fork())) < 0) { if (errno != EAGAIN) { close(p[this]); *************** *** 998,1009 **** sleep(5); } if (pid == 0) { ! this = !this; /* swap this and that */ ! that = !this; ! close(p[that]); ! if (p[this] != (*mode == 'r')) { ! dup2(p[this], *mode == 'r'); ! close(p[this]); } if (doexec) { do_exec(cmd); /* may or may not use the shell */ --- 1075,1086 ---- sleep(5); } if (pid == 0) { ! #define THIS that ! #define THAT this ! close(p[THAT]); ! if (p[THIS] != (*mode == 'r')) { ! dup2(p[THIS], *mode == 'r'); ! close(p[THIS]); } if (doexec) { do_exec(cmd); /* may or may not use the shell */ *************** *** 1012,1019 **** if (tmpstab = stabent("$",allstabs)) str_numset(STAB_STR(tmpstab),(double)getpid()); return Nullfp; } - that = !this; close(p[that]); str = afetch(pidstatary,p[this],TRUE); str_numset(str,(double)pid); --- 1089,1097 ---- if (tmpstab = stabent("$",allstabs)) str_numset(STAB_STR(tmpstab),(double)getpid()); return Nullfp; + #undef THIS + #undef THAT } close(p[that]); str = afetch(pidstatary,p[this],TRUE); str_numset(str,(double)pid); *************** *** 1022,1027 **** --- 1100,1115 ---- return fdopen(p[this], mode); } + #ifndef DUP2 + dup2(oldfd,newfd) + int oldfd; + int newfd; + { + close(newfd); + while (dup(oldfd) != newfd) ; /* good enough for our purposes */ + } + #endif + int mypclose(ptr) FILE *ptr; *************** *** 1084,1086 **** --- 1172,1190 ---- } #endif } + + #ifndef MEMCMP + memcmp(s1,s2,len) + register unsigned char *s1; + register unsigned char *s2; + register int len; + { + register int tmp; + + while (len--) { + if (tmp = *s1++ - *s2++) + return tmp; + } + return 0; + } + #endif /* MEMCMP */ Common subdirectories: beta/x2p and gamma/x2p Common subdirectories: beta/eg/g and gamma/eg/g Common subdirectories: beta/eg/scan and gamma/eg/scan Common subdirectories: beta/eg/van and gamma/eg/van diff -c -r beta/lib/dumpvar.pl gamma/lib/dumpvar.pl *** beta/lib/dumpvar.pl Fri Sep 15 16:08:58 1989 --- gamma/lib/dumpvar.pl Fri Sep 15 16:13:27 1989 *************** *** 6,28 **** while (($key,$val) = each(%stab)) { { local(*entry) = $val; ! eval <<'.' if defined $entry; ! print "\$$key = '$entry'\n"; ! . ! eval <<'.' if defined @entry; ! print "\@$key = (\n"; ! foreach $num ($[ .. $#entry) { ! print " $num\t'",$entry[$num],"'\n"; ! } ! print ")\n"; ! . ! eval <<'.' if $key ne "_$package" && defined %entry; ! print "\%$key = (\n"; ! foreach $key (sort keys(%entry)) { ! print " $key\t'",$entry{$key},"'\n"; ! } ! print ")\n"; ! . } } } --- 6,28 ---- while (($key,$val) = each(%stab)) { { local(*entry) = $val; ! if (defined $entry) { ! print "\$$key = '$entry'\n"; ! } ! if (defined @entry) { ! print "\@$key = (\n"; ! foreach $num ($[ .. $#entry) { ! print " $num\t'",$entry[$num],"'\n"; ! } ! print ")\n"; ! } ! if ($key ne "_$package" && defined %entry) { ! print "\%$key = (\n"; ! foreach $key (sort keys(%entry)) { ! print " $key\t'",$entry{$key},"'\n"; ! } ! print ")\n"; ! } } } } diff -c -r beta/lib/getopt.pl gamma/lib/getopt.pl *** beta/lib/getopt.pl Fri Sep 15 16:06:04 1989 --- gamma/lib/getopt.pl Fri Sep 15 16:13:05 1989 *************** *** 17,27 **** ($first,$rest) = ($1,$2); if (index($argumentative,$first) >= $[) { if ($rest ne '') { ! shift; } else { ! shift; ! $rest = shift; } eval "\$opt_$first = \$rest;"; } --- 17,27 ---- ($first,$rest) = ($1,$2); if (index($argumentative,$first) >= $[) { if ($rest ne '') { ! shift(@ARGV); } else { ! shift(@ARGV); ! $rest = shift(@ARGV); } eval "\$opt_$first = \$rest;"; } *************** *** 31,37 **** $ARGV[0] = "-$rest"; } else { ! shift; } } } --- 31,37 ---- $ARGV[0] = "-$rest"; } else { ! shift(@ARGV); } } } Only in gamma/lib: getopts.pl diff -c -r beta/t/TEST gamma/t/TEST *** beta/t/TEST Fri Sep 15 16:08:14 1989 --- gamma/t/TEST Fri Sep 15 16:12:50 1989 *************** *** 5,10 **** --- 5,12 ---- # This is written in a peculiar style, since we're trying to avoid # most of the constructs we'll be testing for. + $| = 1; + if ($ARGV[0] eq '-v') { $verbose = 1; shift; diff -c -r beta/x2p/EXTERN.h gamma/x2p/EXTERN.h *** beta/x2p/EXTERN.h Fri Sep 15 16:09:12 1989 --- gamma/x2p/EXTERN.h Fri Sep 15 16:13:44 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: EXTERN.h,v $ - * Revision 2.0 88/06/05 00:15:24 root - * Baseline version 2.0. - * */ #undef EXT --- 6,11 ---- diff -c -r beta/x2p/INTERN.h gamma/x2p/INTERN.h *** beta/x2p/INTERN.h Fri Sep 15 16:09:13 1989 --- gamma/x2p/INTERN.h Fri Sep 15 16:13:45 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: INTERN.h,v $ - * Revision 2.0 88/06/05 00:15:27 root - * Baseline version 2.0. - * */ #undef EXT --- 6,11 ---- diff -c -r beta/x2p/Makefile.SH gamma/x2p/Makefile.SH *** beta/x2p/Makefile.SH Fri Sep 15 16:07:52 1989 --- gamma/x2p/Makefile.SH Fri Sep 15 16:12:30 1989 *************** *** 44,50 **** mallocsrc = $mallocsrc mallocobj = $mallocobj ! libs = $libnm -lm !GROK!THIS! cat >>Makefile <<'!NO!SUBS!' --- 44,50 ---- mallocsrc = $mallocsrc mallocobj = $mallocobj ! libs = $libnm -lm $libs !GROK!THIS! cat >>Makefile <<'!NO!SUBS!' *************** *** 79,85 **** touch all a2p: $(obj) a2p.o ! $(CC) $(LDFLAGS) $(LARGE) $(obj) a2p.o $(libs) -o a2p a2p.c: a2p.y @ echo Expect 208 shift/reduce conflicts... --- 79,85 ---- touch all a2p: $(obj) a2p.o ! $(CC) $(LARGE) $(LDFLAGS) $(obj) a2p.o $(libs) -o a2p a2p.c: a2p.y @ echo Expect 208 shift/reduce conflicts... *************** *** 89,97 **** a2p.o: a2p.c a2py.c a2p.h EXTERN.h util.h INTERN.h handy.h ../config.h $(CC) -c $(CFLAGS) $(LARGE) a2p.c - # if a .h file depends on another .h file... - $(h): - touch $@ install: a2p s2p # won't work with csh export PATH || exit 1 --- 89,94 ---- diff -c -r beta/x2p/a2p.h gamma/x2p/a2p.h *** beta/x2p/a2p.h Fri Sep 15 16:07:37 1989 --- gamma/x2p/a2p.h Fri Sep 15 16:12:14 1989 *************** *** 6,17 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: a2p.h,v $ - * Revision 2.0.1.1 88/07/11 23:14:35 root - * patch2: added tokens from 1985 awk - * - * Revision 2.0 88/06/05 00:15:33 root - * Baseline version 2.0. - * */ #define VOIDUSED 1 --- 6,11 ---- diff -c -r beta/x2p/a2p.y gamma/x2p/a2p.y *** beta/x2p/a2p.y Fri Sep 15 16:07:15 1989 --- gamma/x2p/a2p.y Fri Sep 15 16:11:59 1989 *************** *** 7,24 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: a2p.y,v $ - * Revision 2.0.1.3 88/08/05 01:30:15 root - * patch13: a2p was treating strings and numbers as variables - * - * Revision 2.0.1.2 88/08/03 22:49:27 root - * patch11: in a2p, newlines weren't allowed following comma - * - * Revision 2.0.1.1 88/07/11 23:20:14 root - * patch2: changes to support translation of 1985 awk - * - * Revision 2.0 88/06/05 00:15:38 root - * Baseline version 2.0. - * */ #include "INTERN.h" --- 7,12 ---- diff -c -r beta/x2p/a2py.c gamma/x2p/a2py.c *** beta/x2p/a2py.c Fri Sep 15 16:07:00 1989 --- gamma/x2p/a2py.c Fri Sep 15 16:11:30 1989 *************** *** 6,28 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: a2py.c,v $ - * Revision 2.0.1.4 88/10/31 16:52:13 lwall - * patch15: deleted some duplicate $ characters - * - * Revision 2.0.1.3 88/09/07 17:15:57 lwall - * patch14: walk() needed to be declared outside of main() - * - * Revision 2.0.1.2 88/08/03 22:50:05 root - * patch11: in a2p, numbers couldn't start with '.' - * - * Revision 2.0.1.1 88/07/11 23:25:33 root - * patch2: changes to support translation of 1985 awk - * patch2: now fixes any perl reserved words it finds - * patch2: now checks for overflow of ops storage area - * - * Revision 2.0 88/06/05 00:15:41 root - * Baseline version 2.0. - * */ #include "util.h" --- 6,11 ---- *************** *** 135,141 **** /* second pass to produce new program */ tmpstr = walk(0,0,root,&i,P_MIN); ! str = str_make("#!/usr/bin/perl\neval \"exec /usr/bin/perl -S $0 $*\"\n\ if $running_under_some_shell;\n\ # this emulates #! processing on NIH machines.\n\ # (remove #! line above if indigestible)\n\n"); --- 118,128 ---- /* second pass to produce new program */ tmpstr = walk(0,0,root,&i,P_MIN); ! str = str_make("#!"); ! str_cat(str, BIN); ! str_cat(str, "/perl\neval \"exec "); ! str_cat(str, BIN); ! str_cat(str, "/perl -S $0 $*\"\n\ if $running_under_some_shell;\n\ # this emulates #! processing on NIH machines.\n\ # (remove #! line above if indigestible)\n\n"); diff -c -r beta/x2p/handy.h gamma/x2p/handy.h *** beta/x2p/handy.h Fri Sep 15 16:08:39 1989 --- gamma/x2p/handy.h Fri Sep 15 16:13:15 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: handy.h,v $ - * Revision 2.0 88/06/05 00:15:47 root - * Baseline version 2.0. - * */ #define Null(type) ((type)0) --- 6,11 ---- diff -c -r beta/x2p/hash.c gamma/x2p/hash.c *** beta/x2p/hash.c Fri Sep 15 16:07:38 1989 --- gamma/x2p/hash.c Fri Sep 15 16:12:18 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: hash.c,v $ - * Revision 2.0 88/06/05 00:15:50 root - * Baseline version 2.0. - * */ #include <stdio.h> --- 6,11 ---- diff -c -r beta/x2p/hash.h gamma/x2p/hash.h *** beta/x2p/hash.h Fri Sep 15 16:08:21 1989 --- gamma/x2p/hash.h Fri Sep 15 16:12:54 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: hash.h,v $ - * Revision 2.0 88/06/05 00:15:52 root - * Baseline version 2.0. - * */ #define FILLPCT 60 /* don't make greater than 99 */ --- 6,11 ---- diff -c -r beta/x2p/str.c gamma/x2p/str.c *** beta/x2p/str.c Fri Sep 15 16:07:22 1989 --- gamma/x2p/str.c Fri Sep 15 16:11:57 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: str.c,v $ - * Revision 2.0 88/06/05 00:16:02 root - * Baseline version 2.0. - * */ #include "handy.h" --- 6,11 ---- diff -c -r beta/x2p/str.h gamma/x2p/str.h *** beta/x2p/str.h Fri Sep 15 16:08:28 1989 --- gamma/x2p/str.h Fri Sep 15 16:13:04 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: str.h,v $ - * Revision 2.0 88/06/05 00:16:05 root - * Baseline version 2.0. - * */ struct string { --- 6,11 ---- diff -c -r beta/x2p/util.c gamma/x2p/util.c *** beta/x2p/util.c Fri Sep 15 16:07:18 1989 --- gamma/x2p/util.c Fri Sep 15 16:12:15 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: util.c,v $ - * Revision 2.0 88/06/05 00:16:07 root - * Baseline version 2.0. - * */ #include <stdio.h> --- 6,11 ---- *************** *** 231,236 **** --- 228,240 ---- { fprintf(stderr,pat,a1,a2,a3,a4); exit(1); + } + + /*VARARGS1*/ + warn(pat,a1,a2,a3,a4) + char *pat; + { + fprintf(stderr,pat,a1,a2,a3,a4); } static bool firstsetenv = TRUE; diff -c -r beta/x2p/util.h gamma/x2p/util.h *** beta/x2p/util.h Fri Sep 15 16:08:40 1989 --- gamma/x2p/util.h Fri Sep 15 16:13:16 1989 *************** *** 6,14 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: util.h,v $ - * Revision 2.0 88/06/05 00:16:10 root - * Baseline version 2.0. - * */ /* is the string for makedir a directory name or a filename? */ --- 6,11 ---- diff -c -r beta/x2p/walk.c gamma/x2p/walk.c *** beta/x2p/walk.c Fri Sep 15 16:05:33 1989 --- gamma/x2p/walk.c Fri Sep 15 16:10:01 1989 *************** *** 6,33 **** * as specified in the README file that comes with the perl 3.0 kit. * * $Log: walk.c,v $ - * Revision 2.0.1.4 88/08/05 01:31:14 root - * patch13: dumb typo in last patch - * - * Revision 2.0.1.3 88/08/03 22:54:39 root - * patch11: a2p was being really stupid about comparisons with literal strings - * patch11: a2p tried to make a local declaration on a null argument list - * patch11: fixed possible null pointer dereference - * patch11: comma didn't allow newline after it - * - * Revision 2.0.1.2 88/07/15 01:39:36 root - * patch9: gcc complained about "\$", so it's now "\\$" - * - * Revision 2.0.1.1 88/07/11 23:35:57 root - * patch2: changes to support translation of 1985 awk - * patch2: handles multiple opens to same file better - * patch2: now handles absence of line actions - * patch2: now takes advantage of perl's filehandle indirection - * patch2: now uses keys() instead of each() to protect against deletes in loop - * - * Revision 2.0 88/06/05 00:16:12 root - * Baseline version 2.0. - * */ #include "handy.h" --- 6,11 ---- diff -c -r beta/PACKINGLIST gamma/PACKINGLIST *** beta/PACKINGLIST Fri Sep 15 16:07:24 1989 --- gamma/PACKINGLIST Fri Sep 15 16:11:48 1989 *************** *** 3,195 **** Filename Kit Description -------- --- ----------- Changes 19 Differences between 2.0 level 18 and 3.0 level 0 ! Configure 3 Run this first ! Copying 12 The GNU General Public License EXTERN.h 23 Included before foreign .h files INTERN.h 23 Included before domestic .h files ! MANIFEST 18 This list of files ! Makefile.SH 18 Precursor to Makefile ! PACKINGLIST 18 Which files came from which kits README 1 The Instructions Wishlist 18 Some things that may or may not happen ! arg.h 9 Public declarations for the above ! array.c 6 Numerically subscripted arrays ! array.h 22 Public declarations for the above ! client 22 A client to test sockets cmd.c 14 Command interpreter ! cmd.h 20 Public declarations for the above ! config.H 4 Sample config.h ! config.h.SH 8 Produces config.h ! cons.c 9 Routines to construct cmd nodes of a parse tree consarg.c 13 Routines to construct arg nodes of a parse tree doarg.c 11 Scalar expression evaluation ! doio.c 8 I/O operations dolist.c 16 Array expression evaluation dump.c 18 Debugging output ! eg/ADB 23 An adb wrapper to put in your crash dir eg/README 1 Intro to example perl scripts ! eg/changes 22 A program to list recently changed files eg/down 23 A program to do things to subdirectories eg/dus 23 A program to do du -s on non-mounted dirs eg/findcp 22 A find wrapper that implements a -cp switch eg/findtar 23 A find wrapper that pumps out a tar file ! eg/g/gcp.man 21 Manual page for gcp eg/g/gcp 21 A program to do a global rcp eg/g/ged 23 A program to do a global edit ! eg/g/ghosts 22 A sample /etc/ghosts file ! eg/g/gsh.man 21 Manual page for gsh ! eg/g/gsh 20 A program to do a global rsh eg/muck.man 23 Manual page for muck eg/muck 21 A program to find missing make dependencies ! eg/myrup 22 A program to find lightly loaded machines eg/nih 23 Script to insert #! workaround ! eg/rmfrom 17 A program to feed doomed filenames to eg/scan/scan_df 22 Scan for filesystem anomalies eg/scan/scan_last 22 Scan for login anomalies ! eg/scan/scan_messages 18 Scan for console message anomalies ! eg/scan/scan_passwd 15 Scan for passwd file anomalies ! eg/scan/scan_ps 22 Scan for process anomalies eg/scan/scan_sudo 22 Scan for sudo anomalies ! eg/scan/scan_suid 21 Scan for setuid anomalies ! eg/scan/scanner 21 An anomaly reporter eg/shmkill 23 A program to remove unused shared memory eg/van/empty 22 A program to empty the trashcan ! eg/van/unvanish 21 A program to undo what vanish does eg/van/vanexp 23 A program to expire vanished files ! eg/van/vanish 21 A program to put files in a trashcan eg/who 23 A sample who program ! eval.c 5 The expression evaluator ! evalargs.xc 12 The arg evaluator of eval.c form.c 19 Format processing ! form.h 22 Public declarations for the above gettest 23 A little script to test the get* routines ! handy.h 21 Handy definitions hash.c 17 Associative arrays ! hash.h 8 Public declarations for the above ! hdef 22 Build database of .h definition locations ! ioctl.pl 20 Sample ioctl.pl ! lib/complete.pl 21 A command completion subroutine lib/dumpvar.pl 23 A variable dumper ! lib/getopt.pl 7 Perl library supporting option parsing lib/importenv.pl 23 Perl routine to get environment into variables lib/perldb.pl 17 Perl debugging routines ! lib/stat.pl 22 Perl library supporting stat function ! lib/termcap.pl 16 Perl library supporting termcap usage ! lib/validate.pl 20 Perl library supporting wholesale file mode validation makedepend.SH 20 Precursor to makedepend makedir.SH 22 Precursor to makedir makelib.SH 20 A thing to turn C .h file into perl .h files ! malloc.c 13 A version of malloc you might not want ! munch 19 Try to make some .h equivalents ! patchlevel.h 6 The current patch level of perl ! perl.h 17 Global declarations perl.man.1 1 The manual page(s), first fourth ! perl.man.2 10 The manual page(s), second fourth ! perl.man.3 7 The manual page(s), third fourth perl.man.4 6 The manual page(s), fourth fourth ! perl.y 10 Yacc grammar for perl perlsh 23 A poor man's perl shell ! perly.c 16 main() regcomp.c 12 Regular expression compiler regcomp.h 19 Private declarations for above ! regexec.c 11 Regular expression evaluator ! regexp.h 22 Public declarations for the above server 23 A server to test sockets ! spat.h 22 Search pattern declarations ! stab.c 7 Symbol table stuff ! stab.h 20 Public declarations for the above ! str.c 14 String handling package str.h 20 Public declarations for the above t/README 1 Instructions for regression tests ! t/TEST 21 The regression tester t/base.cond 23 See if conditionals work ! t/base.if 23 See if if works t/base.lex 22 See if lexical items work ! t/base.pat 3 See if pattern matching works ! t/base.term 22 See if various terms work t/cmd.elsif 23 See if else-if works ! t/cmd.for 22 See if for loops work ! t/cmd.mod 22 See if statement modifiers work ! t/cmd.subval 21 See if subroutine values work ! t/cmd.switch 21 See if switch optimizations work ! t/cmd.while 21 See if while loops work t/comp.cmdopt 21 See if command optimization works ! t/comp.cpp 22 See if C preprocessor works t/comp.decl 23 See if declarations work ! t/comp.multiline 22 See if multiline strings work ! t/comp.package 22 See if packages work t/comp.script 23 See if script invokation works t/comp.term 22 See if more terms work ! t/io.argv 22 See if ARGV stuff works t/io.dup 23 See if >& works right t/io.fs 21 See if directory manipulations work t/io.inplace 23 See if inplace editing works ! t/io.pipe 23 See if secure pipes work t/io.print 23 See if print commands work ! t/io.tell 11 See if file seeking works t/op.append 23 See if . works ! t/op.array 5 See if array operations work ! t/op.auto 21 See if autoincrement et all work ! t/op.chop 23 See if chop works ! t/op.cond 23 See if conditional expressions work ! t/op.dbm 21 See if dbm binding works ! t/op.delete 22 See if delete works ! t/op.do 22 See if subroutines work t/op.each 22 See if associative iterators work t/op.eval 22 See if eval operator works ! t/op.exec 9 See if exec and system work ! t/op.exp 22 See if math functions work t/op.flip 23 See if range operator works ! t/op.fork 23 See if fork works t/op.glob 23 See if <*> works ! t/op.goto 22 See if goto works ! t/op.index 22 See if index works ! t/op.int 23 See if int works ! t/op.join 23 See if join works ! t/op.list 21 See if array lists work ! t/op.local 22 See if local works ! t/op.magic 22 See if magic variables work t/op.mkdir 23 See if mkdir works ! t/op.oct 23 See if oct and hex work t/op.ord 23 See if ord works t/op.pack 23 See if pack and unpack work ! t/op.pat 20 See if esoteric patterns work ! t/op.push 23 See if push and pop work ! t/op.range 22 See if .. works ! t/op.read 22 See if read() works ! t/op.regexp 22 See if regular expressions work ! t/op.repeat 22 See if x operator works ! t/op.sleep 14 See if sleep works t/op.sort 23 See if sort works t/op.split 1 See if split works ! t/op.sprintf 23 See if sprintf works ! t/op.stat 19 See if stat works ! t/op.study 21 See if study works ! t/op.substr 20 See if substr works ! t/op.subst 20 See if substitutions work t/op.time 22 See if time functions work t/op.undef 22 See if undef works ! t/op.unshift 23 See if unshift works ! t/op.vec 22 See if vectors work ! t/op.write 22 See if write works ! t/re_tests 20 Input file for op.regexp ! toke.c 4 The tokener ! util.c 15 Utility routines ! util.h 22 Public declarations for the above x2p/EXTERN.h 23 Same as above x2p/INTERN.h 23 Same as above ! x2p/Makefile.SH 20 Precursor to Makefile ! x2p/a2p.h 19 Global declarations x2p/a2p.man 19 Manual page for awk to perl translator ! x2p/a2p.y 17 A yacc grammer for awk x2p/a2py.c 15 Awk compiler, sort of ! x2p/handy.h 22 Handy definitions ! x2p/hash.c 19 Associative arrays again x2p/hash.h 22 Public declarations for the above ! x2p/s2p.SH 13 Sed to perl translator ! x2p/s2p.man 21 Manual page for sed to perl translator x2p/str.c 18 String handling package ! x2p/str.h 22 Public declarations for the above ! x2p/util.c 17 Utility routines ! x2p/util.h 22 Public declarations for the above ! x2p/walk.c 2 Parse tree walker --- 3,194 ---- Filename Kit Description -------- --- ----------- Changes 19 Differences between 2.0 level 18 and 3.0 level 0 ! Configure 2 Run this first ! Copying 17 The GNU General Public License EXTERN.h 23 Included before foreign .h files INTERN.h 23 Included before domestic .h files ! MANIFEST 7 This list of files ! Makefile.SH 19 Precursor to Makefile ! PACKINGLIST 17 Which files came from which kits README 1 The Instructions Wishlist 18 Some things that may or may not happen ! arg.h 13 Public declarations for the above ! array.c 20 Numerically subscripted arrays ! array.h 23 Public declarations for the above ! client 23 A client to test sockets cmd.c 14 Command interpreter ! cmd.h 21 Public declarations for the above ! config.H 22 Sample config.h ! config.h.SH 10 Produces config.h ! cons.c 10 Routines to construct cmd nodes of a parse tree consarg.c 13 Routines to construct arg nodes of a parse tree doarg.c 11 Scalar expression evaluation ! doio.c 7 I/O operations dolist.c 16 Array expression evaluation dump.c 18 Debugging output ! eg/ADB 6 An adb wrapper to put in your crash dir eg/README 1 Intro to example perl scripts ! eg/changes 23 A program to list recently changed files eg/down 23 A program to do things to subdirectories eg/dus 23 A program to do du -s on non-mounted dirs eg/findcp 22 A find wrapper that implements a -cp switch eg/findtar 23 A find wrapper that pumps out a tar file ! eg/g/gcp.man 22 Manual page for gcp eg/g/gcp 21 A program to do a global rcp eg/g/ged 23 A program to do a global edit ! eg/g/ghosts 23 A sample /etc/ghosts file ! eg/g/gsh.man 22 Manual page for gsh ! eg/g/gsh 21 A program to do a global rsh eg/muck.man 23 Manual page for muck eg/muck 21 A program to find missing make dependencies ! eg/myrup 23 A program to find lightly loaded machines eg/nih 23 Script to insert #! workaround ! eg/rmfrom 8 A program to feed doomed filenames to eg/scan/scan_df 22 Scan for filesystem anomalies eg/scan/scan_last 22 Scan for login anomalies ! eg/scan/scan_messages 20 Scan for console message anomalies ! eg/scan/scan_passwd 23 Scan for passwd file anomalies ! eg/scan/scan_ps 23 Scan for process anomalies eg/scan/scan_sudo 22 Scan for sudo anomalies ! eg/scan/scan_suid 17 Scan for setuid anomalies ! eg/scan/scanner 22 An anomaly reporter eg/shmkill 23 A program to remove unused shared memory eg/van/empty 22 A program to empty the trashcan ! eg/van/unvanish 9 A program to undo what vanish does eg/van/vanexp 23 A program to expire vanished files ! eg/van/vanish 12 A program to put files in a trashcan eg/who 23 A sample who program ! eval.c 4 The expression evaluator ! evalargs.xc 19 The arg evaluator of eval.c form.c 19 Format processing ! form.h 23 Public declarations for the above gettest 23 A little script to test the get* routines ! handy.h 22 Handy definitions hash.c 17 Associative arrays ! hash.h 19 Public declarations for the above ! ioctl.pl 13 Sample ioctl.pl ! lib/complete.pl 22 A command completion subroutine lib/dumpvar.pl 23 A variable dumper ! lib/getopt.pl 23 Perl library supporting option parsing ! lib/getopts.pl 16 Perl library supporting option parsing lib/importenv.pl 23 Perl routine to get environment into variables lib/perldb.pl 17 Perl debugging routines ! lib/stat.pl 23 Perl library supporting stat function ! lib/termcap.pl 21 Perl library supporting termcap usage ! lib/validate.pl 21 Perl library supporting wholesale file mode validation makedepend.SH 20 Precursor to makedepend makedir.SH 22 Precursor to makedir makelib.SH 20 A thing to turn C .h file into perl .h files ! malloc.c 18 A version of malloc you might not want ! patchlevel.h 9 The current patch level of perl ! perl.h 18 Global declarations perl.man.1 1 The manual page(s), first fourth ! perl.man.2 9 The manual page(s), second fourth ! perl.man.3 8 The manual page(s), third fourth perl.man.4 6 The manual page(s), fourth fourth ! perl.y 11 Yacc grammar for perl perlsh 23 A poor man's perl shell ! perly.c 14 main() regcomp.c 12 Regular expression compiler regcomp.h 19 Private declarations for above ! regexec.c 12 Regular expression evaluator ! regexp.h 23 Public declarations for the above server 23 A server to test sockets ! spat.h 4 Search pattern declarations ! stab.c 9 Symbol table stuff ! stab.h 21 Public declarations for the above ! str.c 15 String handling package str.h 20 Public declarations for the above t/README 1 Instructions for regression tests ! t/TEST 22 The regression tester t/base.cond 23 See if conditionals work ! t/base.if 24 See if if works t/base.lex 22 See if lexical items work ! t/base.pat 24 See if pattern matching works ! t/base.term 23 See if various terms work t/cmd.elsif 23 See if else-if works ! t/cmd.for 23 See if for loops work ! t/cmd.mod 23 See if statement modifiers work ! t/cmd.subval 22 See if subroutine values work ! t/cmd.switch 5 See if switch optimizations work ! t/cmd.while 22 See if while loops work t/comp.cmdopt 21 See if command optimization works ! t/comp.cpp 23 See if C preprocessor works t/comp.decl 23 See if declarations work ! t/comp.multiline 23 See if multiline strings work ! t/comp.package 23 See if packages work t/comp.script 23 See if script invokation works t/comp.term 22 See if more terms work ! t/io.argv 23 See if ARGV stuff works t/io.dup 23 See if >& works right t/io.fs 21 See if directory manipulations work t/io.inplace 23 See if inplace editing works ! t/io.pipe 24 See if secure pipes work t/io.print 23 See if print commands work ! t/io.tell 22 See if file seeking works t/op.append 23 See if . works ! t/op.array 21 See if array operations work ! t/op.auto 22 See if autoincrement et all work ! t/op.chop 15 See if chop works ! t/op.cond 24 See if conditional expressions work ! t/op.dbm 22 See if dbm binding works ! t/op.delete 14 See if delete works ! t/op.do 23 See if subroutines work t/op.each 22 See if associative iterators work t/op.eval 22 See if eval operator works ! t/op.exec 23 See if exec and system work ! t/op.exp 23 See if math functions work t/op.flip 23 See if range operator works ! t/op.fork 24 See if fork works t/op.glob 23 See if <*> works ! t/op.goto 23 See if goto works ! t/op.index 23 See if index works ! t/op.int 12 See if int works ! t/op.join 24 See if join works ! t/op.list 20 See if array lists work ! t/op.local 23 See if local works ! t/op.magic 23 See if magic variables work t/op.mkdir 23 See if mkdir works ! t/op.oct 24 See if oct and hex work t/op.ord 23 See if ord works t/op.pack 23 See if pack and unpack work ! t/op.pat 21 See if esoteric patterns work ! t/op.push 24 See if push and pop work ! t/op.range 23 See if .. works ! t/op.read 23 See if read() works ! t/op.regexp 23 See if regular expressions work ! t/op.repeat 23 See if x operator works ! t/op.sleep 7 See if sleep works t/op.sort 23 See if sort works t/op.split 1 See if split works ! t/op.sprintf 24 See if sprintf works ! t/op.stat 20 See if stat works ! t/op.study 22 See if study works ! t/op.substr 6 See if substr works ! t/op.subst 21 See if substitutions work t/op.time 22 See if time functions work t/op.undef 22 See if undef works ! t/op.unshift 24 See if unshift works ! t/op.vec 23 See if vectors work ! t/op.write 23 See if write works ! t/re_tests 21 Input file for op.regexp ! toke.c 5 The tokener ! util.c 16 Utility routines ! util.h 23 Public declarations for the above x2p/EXTERN.h 23 Same as above x2p/INTERN.h 23 Same as above ! x2p/Makefile.SH 21 Precursor to Makefile ! x2p/a2p.h 20 Global declarations x2p/a2p.man 19 Manual page for awk to perl translator ! x2p/a2p.y 18 A yacc grammer for awk x2p/a2py.c 15 Awk compiler, sort of ! x2p/handy.h 23 Handy definitions ! x2p/hash.c 20 Associative arrays again x2p/hash.h 22 Public declarations for the above ! x2p/s2p.SH 8 Sed to perl translator ! x2p/s2p.man 22 Manual page for sed to perl translator x2p/str.c 18 String handling package ! x2p/str.h 23 Public declarations for the above ! x2p/util.c 20 Utility routines ! x2p/util.h 23 Public declarations for the above ! x2p/walk.c 3 Parse tree walker