Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!bcm!bcm.tmc.edu!sob From: sob@bcm.tmc.edu (Stan Barber) Newsgroups: comp.sources.bugs Subject: patch 41 to rn creating rn/rrn combo (1 of 3) Message-ID: <109@gazette.bcm.tmc.edu> Date: 7 Jan 90 11:04:28 GMT Sender: usenet@bcm.tmc.edu Organization: Baylor College of Medicine, Houston, Tx Lines: 2440 Status: O Description: This is an official patch for rn 4.3. It is the first official to originate from someone other than the author of rn, Larry Wall. Larry has agreed to allow me (Stan Barber) to maintain patches to this version of rn until such time that a new release of rn is available. This one logical patch is actually composed of three physical patches numbered 41,42 and 43. Please install all of them if you intend to install any of them. If you missed the other parts, you can get them via the Archive Server by sending mail to "archive-server@bcm.tmc.edu" with the subject line "send public rn.42.patch" for patch #42 or "send public rn.43.patch" for patch #43. Comments or other fixes should be sent to rrn@lib.tmc.edu. This patch fixes the following: a. Official support of NNTP. Once patched, the source will compile for either a standard news environment or one that uses NNTP. b. Supports SunOS 4.X and Ultrix such that manual changes are no longer needed once you have used Configure to set up the environment. c. Support for domain names. This patch will support real domain names so that internet sites don't have to be something.UUCP as well as their real and correct name. d. Improved support for changes in window sizes. If you are reading news with rn in a workstation window and resize the screen, rn will resize, too. e. Increased the size of some internal buffers to cope with the number of newsgroups in today's USENET. Also, updated the documentation and help files to reflect the news hierarchy today. NOTE: Even if you don't intented to use RRN, you will still want to apply this patch to take advantage of all the bug fixes. Fix: cd to your rn source directory and patch away NOTE: You must be running patch 2.0 with patches up though #12 to insure this will patch correctly. It is known for a fact that patch 2.0 with patches up to #7 will fail. Index: patchlevel Prereq: 40 *** patchlevel Mon Feb 2 17:24:23 1987 --- ../rn/patchlevel Mon Nov 6 00:51:21 1989 *************** *** 1 ! Patch #: 40 --- 1 ----- ! Patch #: 41 Index: term.c Prereq: 4.3.1.3 *** term.c Fri Nov 21 16:39:32 1986 --- ../rn/term.c Tue Nov 28 01:52:01 1989 *************** *** 1,4 ! /* $Header: term.c,v 4.3.1.3 85/09/10 11:05:23 lwall Exp $ * * $Log: term.c,v $ * Revision 4.3.1.3 85/09/10 11:05:23 lwall --- 1,4 ----- ! /* $Header: term.c,v 4.3.2.3 89/11/28 01:51:58 sob Locked $ * * $Log: term.c,v $ * Revision 4.3.2.3 89/11/28 01:51:58 sob *************** *** 1,6 /* $Header: term.c,v 4.3.1.3 85/09/10 11:05:23 lwall Exp $ * * $Log: term.c,v $ * Revision 4.3.1.3 85/09/10 11:05:23 lwall * Improved %m in in_char(). * --- 1,16 ----- /* $Header: term.c,v 4.3.2.3 89/11/28 01:51:58 sob Locked $ * * $Log: term.c,v $ + * Revision 4.3.2.3 89/11/28 01:51:58 sob + * Now handles SIGWINCH correctly. + * + * Revision 4.3.2.2 89/11/27 01:31:34 sob + * Altered NNTP code per ideas suggested by Bela Lubkin + * + * + * Revision 4.3.2.1 89/11/06 01:02:12 sob + * Added RRN support from NNTP 1.5 + * * Revision 4.3.1.3 85/09/10 11:05:23 lwall * Improved %m in in_char(). * *************** *** 63,68 void pushstring(); #endif /* terminal initialization */ void --- 73,80 ----- void pushstring(); #endif + void line_col_calcs(); + /* terminal initialization */ void *************** *** 121,126 char *tgetstr(); char *s; int status; #ifdef PENDING #ifndef FIONREAD --- 133,141 ----- char *tgetstr(); char *s; int status; + #ifdef TIOCGWINSZ + struct winsize winsize; + #endif #ifdef PENDING #ifndef FIONREAD *************** *** 190,195 } LINES = tgetnum("li"); /* lines per page */ COLS = tgetnum("co"); /* columns on page */ AM = tgetflag("am"); /* terminal wraps automatically? */ XN = tgetflag("xn"); /* then eats next newline? */ VB = Tgetstr("vb"); --- 205,220 ----- } LINES = tgetnum("li"); /* lines per page */ COLS = tgetnum("co"); /* columns on page */ + + #ifdef TIOCGWINSZ + { struct winsize ws; + if (ioctl(0, TIOCGWINSZ, &ws) >= 0 && ws.ws_row > 0 && ws.ws_col > 0) { + LINES = ws.ws_row; + COLS = ws.ws_col; + } + } + #endif + AM = tgetflag("am"); /* terminal wraps automatically? */ XN = tgetflag("xn"); /* then eats next newline? */ VB = Tgetstr("vb"); *************** *** 204,209 else CR = "\r"; } #else ?????? /* Roll your own... */ #endif --- 229,240 ----- else CR = "\r"; } + #ifdef TIOCGWINSZ + if (ioctl(1, TIOCGWINSZ, &winsize)>=0) { + if (winsize.ws_row>0) LINES=winsize.ws_row; + if (winsize.ws_col>0) COLS=winsize.ws_col; + } + #endif #else ?????? /* Roll your own... */ #endif *************** *** 207,229 #else ?????? /* Roll your own... */ #endif ! if (LINES > 0) { /* is this a crt? */ ! if (!initlines) /* no -i? */ ! if (ospeed >= B9600) /* whole page at >= 9600 baud */ ! initlines = LINES; ! else if (ospeed >= B4800) /* 16 lines at 4800 */ ! initlines = 16; ! else /* otherwise just header */ ! initlines = 8; ! } ! else { /* not a crt */ ! LINES = 30000; /* so don't page */ ! CL = "\n\n"; /* put a couple of lines between */ ! if (!initlines) /* make initlines reasonable */ ! initlines = 8; ! } ! if (COLS <= 0) ! COLS = 80; noecho(); /* turn off echo */ crmode(); /* enter cbreak mode */ --- 238,244 ----- #else ?????? /* Roll your own... */ #endif ! line_col_calcs(); noecho(); /* turn off echo */ crmode(); /* enter cbreak mode */ *************** *** 387,392 ch = Null(char); ch = ch; #endif } /* input the 2nd and succeeding characters of a multi-character command */ --- 402,408 ----- ch = Null(char); ch = ch; #endif + return((char) 0); } /* input the 2nd and succeeding characters of a multi-character command */ *************** *** 1023,1025 } } #endif CLEAREOL --- 1039,1089 ----- } } #endif CLEAREOL + + + void + line_col_calcs() + { + if (LINES > 0) { /* is this a crt? */ + if ((!initlines) || (!initlines_specified)) + /* no -i or unreasonable value for initlines */ + if (ospeed >= B9600) /* whole page at >= 9600 baud */ + initlines = LINES; + else if (ospeed >= B4800)/* 16 lines at 4800 */ + initlines = 16; + else /* otherwise just header */ + initlines = 8; + } + else { /* not a crt */ + LINES = 30000; /* so don't page */ + CL = "\n\n"; /* put a couple of lines between */ + if ((!initlines) || (!initlines_specified)) + /* make initlines reasonable */ + initlines = 8; + } + if (COLS <= 0) + COLS = 80; + } + + + #ifdef SIGWINCH + int + winch_catcher() + { + /* Come here if window size change signal received */ + #ifdef TIOCGWINSZ + struct winsize ws; + + if (ioctl(0, TIOCGWINSZ, &ws) >= 0 && ws.ws_row > 0 && ws.ws_col > 0) { + LINES = ws.ws_row; + COLS = ws.ws_col; + line_col_calcs(); + } + #else + ??????? + /* Well, if SIGWINCH is defined, but TIOCGWINSZ isn't, there's */ + /* almost certainly something wrong. Figure it out for yourself, */ + /* because I don't know now to deal :-) */ + #endif + } + #endif Index: range.c *** range.c Sun Dec 17 12:48:02 1989 --- ../rn/range.c Wed Nov 8 03:45:43 1989 *************** *** 0 --- 1,56 ----- + #ifndef lint + static char * rcsid ="$Header: range.c,v 1.1 89/11/08 03:45:39 sob Locked $"; + #endif + /* + *************************************************************************** + This work in its current form is Copyright 1989 Stan Barber + This software may be distributed freely as long as no profit is made from + such distribution and this notice is reproducted in whole. + *************************************************************************** + This software is provided on an "as is" basis with no guarantee of + usefulness or correctness of operation for any purpose, intended or + otherwise. The author is in no way liable for this software's performance + or any damage it may cause to any data of any kind anywhere. + *************************************************************************** + */ + /* + * $Log: range.c,v $ + * Revision 1.1 89/11/08 03:45:39 sob + * Initial revision + * + * + */ + + #include + extern char *rindex(); + char * progname; + + main(argc,argv) + char *argv[]; + int argc; + { + int x,y,i; + + + if ((progname = rindex(argv[0],'/'))== NULL) + progname = argv[0]; + else progname++; + + + if (argc != 3) usage(); + x = atoi(argv[1]); + y = atoi(argv[2]); + if (y < x) usage(); + y++; + + for (i=x;i < y;i++) + printf("%d ",i); + printf("\n"); + + exit(0); + } + + usage(){ + fprintf(stderr,"Usage: %s startnumber endnumber\n",progname); + exit(-1); + } Index: bits.c Prereq: 4.3.1.4 *** bits.c Fri Nov 21 16:48:15 1986 --- ../rn/bits.c Tue Nov 28 01:52:17 1989 *************** *** 1,4 ! /* $Header: bits.c,v 4.3.1.4 86/10/31 15:23:53 lwall Exp $ * * $Log: bits.c,v $ * Revision 4.3.1.4 86/10/31 15:23:53 lwall --- 1,4 ----- ! /* $Header: bits.c,v 4.3.2.3 89/11/28 01:52:02 sob Locked $ * * $Log: bits.c,v $ * Revision 4.3.2.3 89/11/28 01:52:02 sob *************** *** 1,6 /* $Header: bits.c,v 4.3.1.4 86/10/31 15:23:53 lwall Exp $ * * $Log: bits.c,v $ * Revision 4.3.1.4 86/10/31 15:23:53 lwall * Separated firstart into two variables so KILL on new articles won't * accidentally mark articles read. --- 1,13 ----- /* $Header: bits.c,v 4.3.2.3 89/11/28 01:52:02 sob Locked $ * * $Log: bits.c,v $ + * Revision 4.3.2.3 89/11/28 01:52:02 sob + * Removed some lint. + * + * Revision 4.3.2.2 89/11/27 01:30:04 sob + * Altered NNTP code per ideas suggested by Bela Lubkin + * + * * Revision 4.3.1.4 86/10/31 15:23:53 lwall * Separated firstart into two variables so KILL on new articles won't * accidentally mark articles read. *************** *** 400,405 * Xrefs correctly--each article need only match itself to be valid. */ if (inews_site == Nullch || strNE(tmpbuf,inews_site)) { char *t; if (inews_site != Nullch) --- 407,413 ----- * Xrefs correctly--each article need only match itself to be valid. */ if (inews_site == Nullch || strNE(tmpbuf,inews_site)) { + #ifndef NORELAY char *t; #endif if (inews_site != Nullch) *************** *** 401,407 */ if (inews_site == Nullch || strNE(tmpbuf,inews_site)) { char *t; ! if (inews_site != Nullch) free(inews_site); #ifndef NORELAY --- 409,415 ----- if (inews_site == Nullch || strNE(tmpbuf,inews_site)) { #ifndef NORELAY char *t; ! #endif if (inews_site != Nullch) free(inews_site); #ifndef NORELAY *************** *** 416,422 * to the use of the Relay-Version site name. */ rver_buf = fetchlines(artnum,PATH_LINE); ! if ((t = instr(rver_buf,"!")) == Nullch) #endif NORELAY inews_site = savestr(nullstr); else { --- 424,430 ----- * to the use of the Relay-Version site name. */ rver_buf = fetchlines(artnum,PATH_LINE); ! if (instr(rver_buf,"!") == Nullch) #endif NORELAY inews_site = savestr(nullstr); else { Index: art.c Prereq: 4.3.1.5 *** art.c Mon Feb 2 17:24:25 1987 --- ../rn/art.c Tue Nov 7 23:21:12 1989 *************** *** 1,4 ! /* $Header: art.c,v 4.3.1.5 85/09/10 11:07:18 lwall Exp $ * * $Log: art.c,v $ * Revision 4.3.1.5 85/09/10 11:07:18 lwall --- 1,4 ----- ! /* $Header: art.c,v 4.3.2.1 89/11/07 23:20:57 sob Locked $ * * $Log: art.c,v $ * Revision 4.3.2.1 89/11/07 23:20:57 sob *************** *** 1,6 /* $Header: art.c,v 4.3.1.5 85/09/10 11:07:18 lwall Exp $ * * $Log: art.c,v $ * Revision 4.3.1.5 85/09/10 11:07:18 lwall * %m not restored on some returns. * --- 1,9 ----- /* $Header: art.c,v 4.3.2.1 89/11/07 23:20:57 sob Locked $ * * $Log: art.c,v $ + * Revision 4.3.2.1 89/11/07 23:20:57 sob + * Bug fixes for NNTP + * * Revision 4.3.1.5 85/09/10 11:07:18 lwall * %m not restored on some returns. * *************** *** 104,110 if (fstat(artfp->_file,&filestat)) /* get article file stats */ return DA_CLEAN; ! if (filestat.st_mode & S_IFMT != S_IFREG) return DA_NORM; artsize = filestat.st_size; /* from that get article size */ --- 107,113 ----- if (fstat(artfp->_file,&filestat)) /* get article file stats */ return DA_CLEAN; ! if ((filestat.st_mode & S_IFMT) != S_IFREG) return DA_NORM; artsize = filestat.st_size; /* from that get article size */ Index: kitlists.c Prereq: 4.3 *** kitlists.c Fri Nov 21 15:42:53 1986 --- ../rn/kitlists.c Wed Nov 8 03:19:49 1989 *************** *** 1,4 ! /* $Header: kitlists.c,v 4.3 85/05/01 11:42:08 lwall Exp $ * * $Log: kitlists.c,v $ * Revision 4.3 85/05/01 11:42:08 lwall --- 1,4 ----- ! /* $Header: kitlists.c,v 4.3.2.1 89/11/08 03:19:35 sob Locked $ * * $Log: kitlists.c,v $ * Revision 4.3.2.1 89/11/08 03:19:35 sob *************** *** 1,6 /* $Header: kitlists.c,v 4.3 85/05/01 11:42:08 lwall Exp $ * * $Log: kitlists.c,v $ * Revision 4.3 85/05/01 11:42:08 lwall * Baseline for release with 4.3bsd. * --- 1,9 ----- /* $Header: kitlists.c,v 4.3.2.1 89/11/08 03:19:35 sob Locked $ * * $Log: kitlists.c,v $ + * Revision 4.3.2.1 89/11/08 03:19:35 sob + * Removed some dependencies. + * * Revision 4.3 85/05/01 11:42:08 lwall * Baseline for release with 4.3bsd. * *************** *** 31,37 ", argc > 1 ? argv[1] : "MANIFEST.new"); inp = popen(buf,"r"); ! while (fgets(buf,1024,inp) != Nullch) { s = index(buf,' '); *s++ = '\0'; for (i=1; --- 34,40 ----- ", argc > 1 ? argv[1] : "MANIFEST.new"); inp = popen(buf,"r"); ! while (fgets(buf,1024,inp) != (char *)NULL) { s = index(buf,' '); *s++ = '\0'; for (i=1; Index: makedepend.SH Prereq: 4.3.1.2 *** makedepend.SH Fri Nov 21 16:23:27 1986 --- ../rn/makedepend.SH Sun Dec 17 02:53:08 1989 *************** *** 1,5 case $CONFIG in ! '') . config.sh ;; esac echo "Extracting makedepend (with variable substitutions)" $spitshell >makedepend <makedepend <makedepend <makedepend <mbox.saver <mbox.saver <newsetup <newsetup <newsetup <newsetup </tmp/n.tmp\$\$ \\ -e 's/^\([^ ]*\) .*\$/\1:/' \\ -e '/^control:/{' \\ -e " w /tmp/n.test\$\$" \\ -e ' d' \\ -e '}' \\ --- 62,68 ----- $sort <\$active | $sed >/tmp/n.tmp\$\$ \\ -e 's/^\([^ ]*\) .*\$/\1:/' \\ -e '/^control:/{' \\ + -e " s/:/!/" \\ -e " w /tmp/n.test\$\$" \\ -e ' d' \\ -e '}' \\ *************** *** 51,56 -e ' d' \\ -e '}' \\ -e '/^junk:/{' \\ -e " w /tmp/n.test\$\$" \\ -e ' d' \\ -e '}' \\ --- 67,73 ----- -e ' d' \\ -e '}' \\ -e '/^junk:/{' \\ + -e " s/:/!/" \\ -e " w /tmp/n.test\$\$" \\ -e ' d' \\ -e '}' \\ *************** *** 55,60 -e ' d' \\ -e '}' \\ -e '/test:/{' \\ -e " w /tmp/n.test\$\$" \\ -e ' d' \\ -e '}' \\ --- 72,78 ----- -e ' d' \\ -e '}' \\ -e '/test:/{' \\ + -e " s/:/!/" \\ -e " w /tmp/n.test\$\$" \\ -e ' d' \\ -e '}' \\ *************** *** 58,71 -e " w /tmp/n.test\$\$" \\ -e ' d' \\ -e '}' \\ - -e "/^net\./{" \\ - -e " w /tmp/n.net\$\$" \\ - -e ' d' \\ - -e '}' \\ - -e "/^mod\./{" \\ - -e " w /tmp/n.mod\$\$" \\ - -e ' d' \\ - -e '}' \\ -e "/^\$locorg\./{" \\ -e " w /tmp/n.\$locorg\$\$" \\ -e ' d' \\ --- 76,81 ----- -e " w /tmp/n.test\$\$" \\ -e ' d' \\ -e '}' \\ -e "/^\$locorg\./{" \\ -e " w /tmp/n.\$locorg\$\$" \\ -e ' d' \\ *************** *** 78,83 -e " w /tmp/n.\$city\$\$" \\ -e ' d' \\ -e '}' \\ -e "/^\$state\./{" \\ -e " w /tmp/n.\$state\$\$" \\ -e ' d' \\ --- 88,97 ----- -e " w /tmp/n.\$city\$\$" \\ -e ' d' \\ -e '}' \\ + -e "/^\$cntry\./{" \\ + -e " w /tmp/n.\$cntry\$\$" \\ + -e ' d' \\ + -e '}' \\ -e "/^\$state\./{" \\ -e " w /tmp/n.\$state\$\$" \\ -e ' d' \\ *************** *** 81,90 -e "/^\$state\./{" \\ -e " w /tmp/n.\$state\$\$" \\ -e ' d' \\ - -e '}' \\ - -e "/^fa\./{" \\ - -e " w /tmp/n.fa\$\$" \\ - -e ' d' \\ -e '}' $sed /tmp/n.local\$\$ \\ --- 95,100 ----- -e "/^\$state\./{" \\ -e " w /tmp/n.\$state\$\$" \\ -e ' d' \\ -e '}' $sed /tmp/n.local\$\$ \\ *************** *** 88,97 -e '}' $sed /tmp/n.local\$\$ \\ - -e "/^\$cntry\./{" \\ - -e " w /tmp/n.\$cntry\$\$" \\ - -e ' d' \\ - -e '}' \\ -e "/^\$cont\./{" \\ -e " w /tmp/n.\$cont\$\$" \\ -e ' d' \\ --- 98,103 ----- -e '}' $sed /tmp/n.local\$\$ \\ -e "/^\$cont\./{" \\ -e " w /tmp/n.\$cont\$\$" \\ -e ' d' \\ *************** *** 95,101 -e "/^\$cont\./{" \\ -e " w /tmp/n.\$cont\$\$" \\ -e ' d' \\ ! -e '}' \\ -e "/^to\./{" \\ -e " w /tmp/n.to\$\$" \\ -e ' d' \\ --- 101,109 ----- -e "/^\$cont\./{" \\ -e " w /tmp/n.\$cont\$\$" \\ -e ' d' \\ ! -e '}' ! ! $sed /tmp/n.local\$\$ \\ -e "/^to\./{" \\ -e " s/:/!/" \\ -e " w /tmp/n.to\$\$" \\ *************** *** 97,102 -e ' d' \\ -e '}' \\ -e "/^to\./{" \\ -e " w /tmp/n.to\$\$" \\ -e ' d' \\ -e '}' \\ --- 105,111 ----- $sed /tmp/n.local\$\$ \\ -e "/^to\./{" \\ + -e " s/:/!/" \\ -e " w /tmp/n.to\$\$" \\ -e ' d' \\ -e '}' \\ *************** *** 144,150 /tmp/n.\$state\$\$ \\ /tmp/n.\$cntry\$\$ \\ /tmp/n.\$cont\$\$ \\ - /tmp/n.mod\$\$ \\ /tmp/n.news\$\$ \\ /tmp/n.comp\$\$ \\ /tmp/n.sci\$\$ \\ --- 153,158 ----- /tmp/n.\$state\$\$ \\ /tmp/n.\$cntry\$\$ \\ /tmp/n.\$cont\$\$ \\ /tmp/n.news\$\$ \\ /tmp/n.comp\$\$ \\ /tmp/n.sci\$\$ \\ *************** *** 152,159 /tmp/n.soc\$\$ \\ /tmp/n.misc\$\$ \\ /tmp/n.talk\$\$ \\ - /tmp/n.net\$\$ \\ - /tmp/n.fa\$\$ \\ /tmp/n.test\$\$ \\ | $uniq >\$dotdir/.newsrc --- 160,165 ----- /tmp/n.soc\$\$ \\ /tmp/n.misc\$\$ \\ /tmp/n.talk\$\$ \\ /tmp/n.test\$\$ \\ | $uniq >\$dotdir/.newsrc *************** *** 166,172 /tmp/n.\$state\$\$ \\ /tmp/n.\$cntry\$\$ \\ /tmp/n.\$cont\$\$ \\ - /tmp/n.mod\$\$ \\ /tmp/n.news\$\$ \\ /tmp/n.comp\$\$ \\ /tmp/n.sci\$\$ \\ --- 172,177 ----- /tmp/n.\$state\$\$ \\ /tmp/n.\$cntry\$\$ \\ /tmp/n.\$cont\$\$ \\ /tmp/n.news\$\$ \\ /tmp/n.comp\$\$ \\ /tmp/n.sci\$\$ \\ *************** *** 173,180 /tmp/n.soc\$\$ \\ /tmp/n.rec\$\$ \\ /tmp/n.talk\$\$ \\ - /tmp/n.net\$\$ \\ - /tmp/n.fa\$\$ \\ /tmp/n.misc\$\$ \\ /tmp/n.test\$\$ --- 178,183 ----- /tmp/n.soc\$\$ \\ /tmp/n.rec\$\$ \\ /tmp/n.talk\$\$ \\ /tmp/n.misc\$\$ \\ /tmp/n.test\$\$ #NNTP$rm -f \$active *************** *** 176,182 /tmp/n.net\$\$ \\ /tmp/n.fa\$\$ \\ /tmp/n.misc\$\$ \\ ! /tmp/n.test\$\$ $cat <<'EOH' Done. --- 179,186 ----- /tmp/n.rec\$\$ \\ /tmp/n.talk\$\$ \\ /tmp/n.misc\$\$ \\ ! /tmp/n.test\$\$ ! #NNTP$rm -f \$active $cat <<'EOH' Done. *************** *** 182,188 Done. If you have never used the news system before, you may find the articles ! in mod.announce.newuser to be helpful. There is also a manual entry for rn. To get rid of newsgroups you aren't interested in, use the 'u' command. Type h for help at any time while running rn. --- 186,192 ----- Done. If you have never used the news system before, you may find the articles ! in news.announce.newusers to be helpful. There is also a manual entry for rn. To get rid of newsgroups you aren't interested in, use the 'u' command. Type h for help at any time while running rn. *************** *** 188,192 Type h for help at any time while running rn. EOH !GROK!THIS! $eunicefix newsetup chmod 755 newsetup --- 192,201 ----- Type h for help at any time while running rn. EOH !GROK!THIS! + case "$isrrn" in + define) sed < newsetup -e '/^#NNTP/s/^#NNTP//' -e '/^#NORMAL/d' > newsetup.new ;; + *) sed < newsetup -e '/^#NNTP/d' -e '/^#NORMAL/s/^#NORMAL//' > newsetup.new ;; + esac + mv newsetup.new newsetup $eunicefix newsetup chmod 755 newsetup Index: newsgroups.SH *** newsgroups.SH Fri Nov 21 15:42:50 1986 --- ../rn/newsgroups.SH Wed Nov 8 01:13:38 1989 *************** *** 1,5 case $CONFIG in ! '') . config.sh ;; esac echo "Extracting newsgroups (with variable substitutions)" $spitshell >newsgroups <newsgroups <newsgroups <newsgroups < newsgroups.new ;; + *) sed < newsgroups -e '/^#NNTP/d' -e '/^#NORMAL/s/^#NORMAL//' > newsgroups.new ;; + esac + mv newsgroups.new newsgroups $eunicefix newsgroups chmod 755 newsgroups Index: newsnews.SH *** newsnews.SH Fri Nov 21 15:42:52 1986 --- ../rn/newsnews.SH Sun Nov 26 18:29:26 1989 *************** *** 23,28 her own message whenever something new happens to rn, and then the file will again be displayed, just once for each person. ! Larry Wall sdcrdcf!lwall !GROK!THIS! $eunicefix newsnews --- 23,28 ----- her own message whenever something new happens to rn, and then the file will again be displayed, just once for each person. ! Larry Wall lwall@jpl-devvax.jpl.nasa.gov !GROK!THIS! $eunicefix newsnews Index: norm.saver.SH *** norm.saver.SH Fri Nov 21 16:25:04 1986 --- ../rn/norm.saver.SH Tue Nov 28 00:08:32 1989 *************** *** 4,10 echo "Extracting norm.saver (with variable substitutions)" $spitshell >norm.saver <norm.saver < .br Regular expression routines are borrowed from emacs, by James Gosling. .SH FILES --- 1638,1644 ----- .I rn that it should gobble up one character after the F. .SH AUTHOR ! Larry Wall .br Regular expression routines are borrowed from emacs, by James Gosling. .SH FILES *************** *** 1646,1652 .Ip "%./.rnlast" 1.25i info from last run of rn .Ip "%./.rnsoft" 1.25i ! soft pointers into /usr/lib/active to speed startup, synchronous with .I .newsrc .Ip "%./.rnhead" 1.25i temporary header file to pass to a mailer or news poster --- 1654,1660 ----- .Ip "%./.rnlast" 1.25i info from last run of rn .Ip "%./.rnsoft" 1.25i ! soft pointers into /usr/lib/news/active to speed startup, synchronous with .I .newsrc .Ip "%./.rnhead" 1.25i temporary header file to pass to a mailer or news poster *************** *** 1655,1661 .Ip "%p" 1.25i your news save directory, usually ~/News .Ip "%x/active" 1.25i ! the list of active newsgroups, usually /usr/lib/news/active .Ip "%P" 1.25i the public news spool directory, usually /usr/spool/news .Ip "%X/INIT" 1.25i --- 1663,1669 ----- .Ip "%p" 1.25i your news save directory, usually ~/News .Ip "%x/active" 1.25i ! the list of active newsgroups, usually /usr/lib/news/active on systems that don't use NNTP .Ip "%P" 1.25i the public news spool directory, usually /usr/spool/news on systems that don't use NNTP .Ip "%X/INIT" 1.25i *************** *** 1657,1663 .Ip "%x/active" 1.25i the list of active newsgroups, usually /usr/lib/news/active .Ip "%P" 1.25i ! the public news spool directory, usually /usr/spool/news .Ip "%X/INIT" 1.25i system-wide default switches .SH SEE ALSO --- 1665,1671 ----- .Ip "%x/active" 1.25i the list of active newsgroups, usually /usr/lib/news/active on systems that don't use NNTP .Ip "%P" 1.25i ! the public news spool directory, usually /usr/spool/news on systems that don't use NNTP .Ip "%X/INIT" 1.25i system-wide default switches .SH SEE ALSO Index: rn.c Prereq: 4.3.1.4 *** rn.c Fri Nov 21 16:39:27 1986 --- ../rn/rn.c Tue Nov 28 01:51:28 1989 *************** *** 1,6 /* rn -- new readnews program * ! * From: lwall@sdcrdcf.UUCP (Larry Wall) * Organization: System Development Corporation, Santa Monica * * begun: 01/14/83 --- 1,6 ----- /* rn -- new readnews program * ! * Original Author: lwall@sdcrdcf.UUCP (Larry Wall) * Organization: System Development Corporation, Santa Monica * * begun: 01/14/83 *************** *** 6,12 * begun: 01/14/83 * 1.0: 04/08/83 * 2.0: 09/01/83 ! */ static char rnid[] = "@(#)$Header: rn.c,v 4.3.1.4 85/09/10 11:05:13 lwall Exp $"; --- 6,13 ----- * begun: 01/14/83 * 1.0: 04/08/83 * 2.0: 09/01/83 ! * RRN/RN: 11/01/89 ! */ static char rnid[] = "@(#)$Header: rn.c,v 4.3.2.2 89/11/28 01:51:25 sob Locked $"; *************** *** 8,14 * 2.0: 09/01/83 */ ! static char rnid[] = "@(#)$Header: rn.c,v 4.3.1.4 85/09/10 11:05:13 lwall Exp $"; /* $Log: rn.c,v $ * Revision 4.3.1.4 85/09/10 11:05:13 lwall --- 9,15 ----- * RRN/RN: 11/01/89 */ ! static char rnid[] = "@(#)$Header: rn.c,v 4.3.2.2 89/11/28 01:51:25 sob Locked $"; /* $Log: rn.c,v $ * Revision 4.3.2.2 89/11/28 01:51:25 sob *************** *** 11,16 static char rnid[] = "@(#)$Header: rn.c,v 4.3.1.4 85/09/10 11:05:13 lwall Exp $"; /* $Log: rn.c,v $ * Revision 4.3.1.4 85/09/10 11:05:13 lwall * Improved %m in in_char(). * --- 12,24 ----- static char rnid[] = "@(#)$Header: rn.c,v 4.3.2.2 89/11/28 01:51:25 sob Locked $"; /* $Log: rn.c,v $ + * Revision 4.3.2.2 89/11/28 01:51:25 sob + * Removed redundant #include directive. + * + * Revision 4.3.2.1 89/11/08 02:27:38 sob + * Release of RN 4.3 with RRN that can be compiled from the same + * sources as either version of the program. + * * Revision 4.3.1.4 85/09/10 11:05:13 lwall * Improved %m in in_char(). * *************** *** 47,53 #include "sw.h" #include "addng.h" #include "ng.h" - #include "INTERN.h" void rn_init() --- 55,60 ----- #include "sw.h" #include "addng.h" #include "ng.h" void rn_init() Index: util.c Prereq: 4.3.1.2 *** util.c Fri Nov 21 16:24:16 1986 --- ../rn/util.c Sun Dec 17 01:55:41 1989 *************** *** 1,4 ! /* $Header: util.c,v 4.3.1.2 85/05/15 14:44:27 lwall Exp $ * * $Log: util.c,v $ * Revision 4.3.1.2 85/05/15 14:44:27 lwall --- 1,4 ----- ! /* $Header: util.c,v 4.3.2.4 89/12/14 23:58:54 sob Exp $ * * $Log: util.c,v $ * Revision 4.3.2.4 89/12/14 23:58:54 sob *************** *** 1,6 /* $Header: util.c,v 4.3.1.2 85/05/15 14:44:27 lwall Exp $ * * $Log: util.c,v $ * Revision 4.3.1.2 85/05/15 14:44:27 lwall * Last arg of execl changed from 0 to Nullch [(char*)0]. * --- 1,18 ----- /* $Header: util.c,v 4.3.2.4 89/12/14 23:58:54 sob Exp $ * * $Log: util.c,v $ + * Revision 4.3.2.4 89/12/14 23:58:54 sob + * Fixed small bug reported by fletcher@cs.utexas.edu in getwd(). + * + * Revision 4.3.2.3 89/11/08 04:47:11 sob + * Added VOIDSIG handling for SunOS 4.X + * + * Revision 4.3.2.2 89/11/07 23:19:35 sob + * Bug fixes for SIGSTP problems + * + * Revision 4.3.2.1 89/11/06 01:03:21 sob + * Added RRN support from NNTP 1.5 + * * Revision 4.3.1.2 85/05/15 14:44:27 lwall * Last arg of execl changed from 0 to Nullch [(char*)0]. * *************** *** 32,37 char *s, *shl; { int status, pid, w; register int (*istat)(), (*qstat)(); int (*signal())(); char *shell; --- 44,52 ----- char *s, *shl; { int status, pid, w; + #ifdef VOIDSIG + int mask; + #else register int (*istat)(), (*qstat)(); int (*signal())(); #endif *************** *** 34,39 int status, pid, w; register int (*istat)(), (*qstat)(); int (*signal())(); char *shell; #ifdef SIGTSTP --- 49,55 ----- #else register int (*istat)(), (*qstat)(); int (*signal())(); + #endif char *shell; #ifdef SIGTSTP *************** *** 38,44 #ifdef SIGTSTP sigset(SIGTSTP,SIG_DFL); ! sigset(SIGCONT,SIG_DFL); #endif if (shl != Nullch) shell = shl; --- 54,61 ----- #ifdef SIGTSTP sigset(SIGTSTP,SIG_DFL); ! sigset(SIGTTOU,SIG_DFL); ! sigset(SIGTTIN,SIG_DFL); #endif if (shl != Nullch) shell = shl; *************** *** 45,50 else if ((shell = getenv("SHELL")) == Nullch || !*shell) shell = PREFSHELL; if ((pid = vfork()) == 0) { if (*s) execl(shell, shell, "-c", s, Nullch); else --- 62,76 ----- else if ((shell = getenv("SHELL")) == Nullch || !*shell) shell = PREFSHELL; if ((pid = vfork()) == 0) { + #ifdef SERVER + int i; + + /* This is necessary to keep bourne shell from puking */ + + for (i = 3; i < 10; ++i) + (void) close(i); + #endif SERVER + if (*s) execl(shell, shell, "-c", s, Nullch); else *************** *** 51,56 execl(shell, shell, Nullch, Nullch, Nullch); _exit(127); } #ifndef lint istat = signal(SIGINT, SIG_IGN); qstat = signal(SIGQUIT, SIG_IGN); --- 77,87 ----- execl(shell, shell, Nullch, Nullch, Nullch); _exit(127); } + #ifdef VOIDSIG + mask = sigblock(0); + signal(SIGINT, SIG_IGN); + signal(SIGQUIT, SIG_IGN); + #else #ifndef lint istat = signal(SIGINT, SIG_IGN); qstat = signal(SIGQUIT, SIG_IGN); *************** *** 58,63 istat = Null(int (*)()); qstat = Null(int (*)()); #endif lint waiting = TRUE; while ((w = wait(&status)) != pid && w != -1) ; --- 89,95 ----- istat = Null(int (*)()); qstat = Null(int (*)()); #endif lint + #endif waiting = TRUE; while ((w = wait(&status)) != pid && w != -1) ; *************** *** 64,69 if (w == -1) status = -1; waiting = FALSE; signal(SIGINT, istat); signal(SIGQUIT, qstat); #ifdef SIGTSTP --- 96,106 ----- if (w == -1) status = -1; waiting = FALSE; + #ifdef VOIDSIG + signal(SIGINT, SIG_DFL); + signal(SIGQUIT, SIG_DFL); + sigsetmask(mask); + #else signal(SIGINT, istat); signal(SIGQUIT, qstat); #endif *************** *** 66,71 waiting = FALSE; signal(SIGINT, istat); signal(SIGQUIT, qstat); #ifdef SIGTSTP sigset(SIGTSTP,stop_catcher); sigset(SIGCONT,cont_catcher); --- 103,109 ----- #else signal(SIGINT, istat); signal(SIGQUIT, qstat); + #endif #ifdef SIGTSTP sigset(SIGTSTP,stop_catcher); sigset(SIGTTOU,stop_catcher); *************** *** 68,74 signal(SIGQUIT, qstat); #ifdef SIGTSTP sigset(SIGTSTP,stop_catcher); ! sigset(SIGCONT,cont_catcher); #endif return status; } --- 106,113 ----- #endif #ifdef SIGTSTP sigset(SIGTSTP,stop_catcher); ! sigset(SIGTTOU,stop_catcher); ! sigset(SIGTTIN,stop_catcher); #endif return status; } *************** *** 320,326 FILE *popen(); FILE *pipefp = popen("/bin/pwd","r"); ! if (pipefd == Nullfp) { printf("Can't run /bin/pwd\n") FLUSH; finalize(1); } --- 359,365 ----- FILE *popen(); FILE *pipefp = popen("/bin/pwd","r"); ! if (pipefp == Nullfp) { printf("Can't run /bin/pwd\n") FLUSH; finalize(1); } Index: Rnmail.SH Prereq: 4.3.1.4 *** Rnmail.SH Fri Nov 21 16:28:11 1986 --- ../rn/Rnmail.SH Mon Nov 6 00:31:06 1989 *************** *** 4,10 echo "Extracting Rnmail (with variable substitutions)" $spitshell >Rnmail <Rnmail <