[comp.sources.bugs] RN Patch #48

rrn@lib.tmc.edu (Stan Barber) (11/10/90)

Description:
	This is an official patch for rn 4.3. This is patch 48.

	If you need the other patches, you can get them via the Archive Server
	by sending mail to "archive-server@bcm.tmc.edu" with the subject line
	of the form "send public rn.XX.patch". Note that only patches 41 and
	later are available from this resource at this time.

	The fully patched rn kit is also available via anonymous ftp from
	lib.tmc.edu and gazette.bcm.tmc.edu. Look in public/rn.

	This patch fixes the following problems or adds the following new
	features:

	Modified Configure to detect the presence of /usr/include/sys/ptem.h
	and modfied common.h to include it if present. This fixes problems
	with late versions of System V.3 that have support for pseudo-terminals
	with windows that might change size. (/usr/include/sys/stream.h is
	included as well.)

	Altered Configure to be smarter about determining if a system was USG
	or not. This is very helpful with the large number of USG machines
	that have certain features of BSD in them, but not quite enough to
	make the purely BSD version of rn/rrn work.

	Added another response when rn asks to add newsgroups. Answering the
	question with a capital Y will add all new newsgroups to the end of
	the .newsrc. Actually, this worked for regular rn users before patch
	48, but now it works for NNTP users and is in the manual page.

	Altered the logic for how rrn determined if a new group came into
	being. It is now much more reliable about making this determination.

	Added logic to make rn/rrn abort rewriting the .newsrc if there is no
	disk space in which to write it. It will now just restore the old
	.newsrc and exit.

	Altered Configure and util.c to hopefully get the usage of getwd()
	and getcwd() straight.

	Fixed Pnews.header to search a USG style password file correctly.

	Increased the size of LBUFLEN from 512 to 1024.

	

This version has been sucessfully compiled and used as rrn on the following
systems:
	IRIS 4D running IRIX 3.3
	Unisys 5000/50 running System V.2
	Wyse 386 running SCO Xenix 2.3 (with TCP 1.0)
	Sun 3/4 running SunOS 4.1
	Solboune 5/600 running OS/SMP 4.0D
	Generic 386 with Interactive System V/386 Release 3.2

This version has been run as rn on a VAX running Ultrix 3.1.
Fix:
	cd to your rn source directory and patch away

Index: Configure
Prereq: 4.3.2.25
*** old/Configure	Thu Nov  8 03:03:31 1990
--- new/Configure	Sat Nov 10 00:09:03 1990
***************
*** 3,9
  # If these # comments don't work, trim them.  Don't worry about the other
  # shell scripts, Configure will trim # comments from them for you.
  #
! # $Header: Configure,v 4.3.2.25 90/05/12 17:34:53 sob Exp $
  #
  # $Log:	Configure,v $
  # Revision 4.3.2.25  90/05/12  17:34:53  sob

--- 3,9 -----
  # If these # comments don't work, trim them.  Don't worry about the other
  # shell scripts, Configure will trim # comments from them for you.
  #
! # $Header: Configure,v 4.3.2.31 90/11/10 00:08:08 sob Exp $
  #
  # $Log:	Configure,v $
  # Revision 4.3.2.31  90/11/10  00:08:08  sob
***************
*** 6,11
  # $Header: Configure,v 4.3.2.25 90/05/12 17:34:53 sob Exp $
  #
  # $Log:	Configure,v $
  # Revision 4.3.2.25  90/05/12  17:34:53  sob
  # Still more XENIX fixes and fixes for using socketlib when rrn and not when
  # just rn.

--- 6,32 -----
  # $Header: Configure,v 4.3.2.31 90/11/10 00:08:08 sob Exp $
  #
  # $Log:	Configure,v $
+ # Revision 4.3.2.31  90/11/10  00:08:08  sob
+ # This one appears to work for Interactive Unix.
+ # 
+ # Revision 4.3.2.30  90/11/09  23:29:16  sob
+ # Added a few line for making rrn under Interactive Unix easier.
+ # 
+ # Revision 4.3.2.29  90/11/05  23:26:21  sob
+ # Added detection of /usr/include/sys/ptem.h for more recent versions
+ # of System V.
+ # 
+ # Revision 4.3.2.28  90/11/04  03:35:01  sob
+ # Added better detection for getwd() and getcwd(). This will hopefully be
+ # the last hurrah of this problem (naive, aren't I?)
+ # 
+ # Revision 4.3.2.27  90/10/06  11:54:56  sob
+ # Added check for memcpy/bcopy.
+ # 
+ # Revision 4.3.2.26  90/10/01  01:39:43  sob
+ # Altered the FLAGS for SCO Xenix 286. The old one are commented out. Let's
+ # see if this works better.
+ # 
  # Revision 4.3.2.25  90/05/12  17:34:53  sob
  # Still more XENIX fixes and fixes for using socketlib when rrn and not when
  # just rn.
***************
*** 186,191
  cntrypref=''
  contpref=''
  strchr=''
  novoid=''
  novfork=''
  portable=''

--- 207,213 -----
  cntrypref=''
  contpref=''
  strchr=''
+ memcpy=''
  novoid=''
  novfork=''
  portable=''
***************
*** 196,201
  termio=''
  fcntl=''
  ioctl=''
  normsig=''
  sigblock=''
  sigret=''

--- 218,224 -----
  termio=''
  fcntl=''
  ioctl=''
+ ptem=''
  normsig=''
  sigblock=''
  sigret=''
***************
*** 201,206
  sigret=''
  getuidgid=''
  getcwd=''
  havetlib=''
  getpwent=''
  gethostname=''

--- 224,230 -----
  sigret=''
  getuidgid=''
  getcwd=''
+ getwd=''
  havetlib=''
  getpwent=''
  gethostname=''
***************
*** 343,349
  		cat <<'EOM'
   
  I can't seem to find your C library.  I've looked for /lib/libc.a and
! /usr/lib/libc.a, but neither of those are there.  What is the full name
  EOM
  	    echo $n "of your C library? $c"
  	    . myread

--- 367,375 -----
  		cat <<'EOM'
   
  I can't seem to find your C library.  I've looked for /lib/libc.a and
! /usr/lib/libc.a, but neither of those are there. Perhaps you can find
! out by reading `man 3 intro' if you have the 'man' facility installed.
! 
  EOM
  	    echo $n "What is the full name of your C library? $c"
  	    . myread
***************
*** 345,351
  I can't seem to find your C library.  I've looked for /lib/libc.a and
  /usr/lib/libc.a, but neither of those are there.  What is the full name
  EOM
! 	    echo $n "of your C library? $c"
  	    . myread
  	    libc="$ans"
  	    fi

--- 371,377 -----
  out by reading `man 3 intro' if you have the 'man' facility installed.
  
  EOM
! 	    echo $n "What is the full name of your C library? $c"
  	    . myread
  	    libc="$ans"
  	    fi
***************
*** 354,360
  fi
  echo " "
  echo $n "Extracting names from $libc for later perusal...$c"
! if ar t $libc > libc.list; then
      echo "done"
  else
      echo " "

--- 380,386 -----
  fi
  echo " "
  echo $n "Extracting names from $libc for later perusal...$c"
! if ar t $libc >libc.list 2>/dev/null; then
      echo "done"
  else
      if $contains SIGAPOLLO /usr/include/signal.h >/dev/null 2>&1; then
***************
*** 357,365
  if ar t $libc > libc.list; then
      echo "done"
  else
!     echo " "
!     echo "The archiver doesn't think $libc is a reasonable library."
!     exit 1
  fi
  : make some quick guesses about what we are up against
  echo " "

--- 383,406 -----
  if ar t $libc >libc.list 2>/dev/null; then
      echo "done"
  else
!     if $contains SIGAPOLLO /usr/include/signal.h >/dev/null 2>&1; then
! 	cat <<'EOM'
!  (AHA, you are
! an Apollo user. In case you didn't already know, the pathname of your
! EOM
! 	echo $n "C library ought to be /lib/clib)...$c"
! 	if nm -g $libc | sed -e 's/$/.o/' >libc.list; then
! 	    echo "done"
! 	else
! 	    echo " "
! 	    echo "Apparently $libc is not an object module. Try again."
! 	    exit 1
! 	fi
!     else
! 	echo " "
! 	echo "The archiver doesn't think $libc is a reasonable library."
! 	exit 1
!     fi
  fi
  : make some quick guesses about what we are up against
  echo " "
***************
*** 364,370
  : make some quick guesses about what we are up against
  echo " "
  echo $n "Hmm...  $c"
! if $contains SIGTSTP /usr/include/signal.h >/dev/null 2>&1 ; then
      echo "Looks kind of like a BSD system, but we'll see..."
      echo exit 0 >bsd
      echo exit 1 >usg

--- 405,411 -----
  : make some quick guesses about what we are up against
  echo " "
  echo $n "Hmm...  $c"
! if $contains sigvec.o libc.list >/dev/null 2>&1 ; then
      echo "Looks kind of like a BSD system, but we'll see..."
      echo exit 0 >bsd
      echo exit 1 >usg
***************
*** 370,378
      echo exit 1 >usg
      echo exit 1 >v7
  else
!     if $contains SIGTSTP /usr/include/sys/signal.h >/dev/null 2>&1 ; then
! 	echo "Looks sort of like a BSD system, but we'll see..."
! 	echo exit 0 >bsd
  	echo exit 1 >usg
  	echo exit 1 >v7
      else

--- 411,419 -----
      echo exit 1 >usg
      echo exit 1 >v7
  else
!     if $contains dup2.o libc.list >/dev/null 2>&1 ; then
! 	echo "Looks sort of like a V7 system, but we'll see..."
! 	echo exit 1 >bsd
  	echo exit 1 >usg
  	echo exit 0 >v7
      else
***************
*** 374,380
  	echo "Looks sort of like a BSD system, but we'll see..."
  	echo exit 0 >bsd
  	echo exit 1 >usg
! 	echo exit 1 >v7
      else
  	if $contains fcntl.o libc.list >/dev/null 2>&1 ; then
  	    echo "Looks kind of like a USG system, but we'll see..."

--- 415,421 -----
  	echo "Looks sort of like a V7 system, but we'll see..."
  	echo exit 1 >bsd
  	echo exit 1 >usg
! 	echo exit 0 >v7
      else
  	    echo "Looks kind of like a USG system, but we'll see..."
  	    echo exit 1 >bsd
***************
*** 376,382
  	echo exit 1 >usg
  	echo exit 1 >v7
      else
- 	if $contains fcntl.o libc.list >/dev/null 2>&1 ; then
  	    echo "Looks kind of like a USG system, but we'll see..."
  	    echo exit 1 >bsd
  	    echo exit 0 >usg

--- 417,422 -----
  	echo exit 1 >usg
  	echo exit 0 >v7
      else
  	    echo "Looks kind of like a USG system, but we'll see..."
  	    echo exit 1 >bsd
  	    echo exit 0 >usg
***************
*** 381,392
  	    echo exit 1 >bsd
  	    echo exit 0 >usg
  	    echo exit 1 >v7
- 	else
- 	    echo "Looks kind of like a version 7 system, but we'll see..."
- 	    echo exit 1 >bsd
- 	    echo exit 1 >usg
- 	    echo exit 0 >v7
- 	fi
      fi
  fi
  if $contains vmssystem.o libc.list >/dev/null 2>&1 ; then

--- 421,426 -----
  	    echo exit 1 >bsd
  	    echo exit 0 >usg
  	    echo exit 1 >v7
      fi
  fi
  :
***************
*** 389,394
  	fi
      fi
  fi
  if $contains vmssystem.o libc.list >/dev/null 2>&1 ; then
      cat <<'EOI'
  There is, however, a strange, musty smell in the air that reminds me of

--- 423,435 -----
  	    echo exit 1 >v7
      fi
  fi
+ :
+ if test -f /etc/inittab; then
+     echo "You have an inittab file. You must be a USG system!"
+     echo exit 1 >bsd
+     echo exit 0 >usg
+     echo exit 1 >v7
+ fi
  if $contains vmssystem.o libc.list >/dev/null 2>&1 ; then
      cat <<'EOI'
  There is, however, a strange, musty smell in the air that reminds me of
***************
*** 1279,1284
  	*)     strchr=define ;;
      esac
  fi
  
  : determine how to determine when a file is a mailbox
  case "$mboxchar" in

--- 1320,1342 -----
  	*)     strchr=define ;;
      esac
  fi
+ if $contains bcopy.o libc.list >/dev/null 2>&1 ; then
+     $echo "Your system appears to use bcopy() rather than memcpy()."
+     $echo $n "Is this correct? [y] $c"
+     . myread
+     case $ans in
+ 	n*|f*) memcpy='define' ;;
+ 	*)     memcpy='undef' ;;
+     esac
+ else
+     $echo "Your system appears to use memcpy() rather than bcopy()."
+     $echo $n "Is this correct? [y] $c"
+     . myread
+     case $ans in
+ 	n*|f*) memcpy=undef ;;
+ 	*)     memcpy=define ;;
+     esac
+ fi
  
  : determine how to determine when a file is a mailbox
  case "$mboxchar" in
***************
*** 1433,1438
      $echo "sys/ioctl.h not found, assuming ioctl args are defined in sgtty.h."
  fi
  
  : see if the system has sigblock
  if $contains sigblock.o libc.list >/dev/null 2>&1 ; then
      $echo "sigblock() found."

--- 1491,1504 -----
      $echo "sys/ioctl.h not found, assuming ioctl args are defined in sgtty.h."
  fi
  
+ : see if ptem.h exists
+ if $test -r /usr/include/sys/ptem.h ; then
+     ptem=define
+     $echo "sys/ptem.h found."
+ else
+     ptem=undef
+ fi
+ 
  : see if the system has sigblock
  if $contains sigblock.o libc.list >/dev/null 2>&1 ; then
      $echo "sigblock() found."
***************
*** 1445,1450
  if $contains getwd.o libc.list >/dev/null 2>&1 ; then
      $echo "getwd() found."
      getcwd=undef
  else
  : see if the system has getcwd
  if $contains getcwd.o libc.list >/dev/null 2>&1 ; then

--- 1511,1517 -----
  if $contains getwd.o libc.list >/dev/null 2>&1 ; then
      $echo "getwd() found."
      getcwd=undef
+     getwd=define
  else
  : see if the system has getcwd
  if $contains getcwd.o libc.list >/dev/null 2>&1 ; then
***************
*** 1450,1455
  if $contains getcwd.o libc.list >/dev/null 2>&1 ; then
      $echo "getcwd() found."
      getcwd=define
  else
      getcwd=undef
  fi

--- 1517,1523 -----
  if $contains getcwd.o libc.list >/dev/null 2>&1 ; then
      $echo "getcwd() found."
      getcwd=define
+     getwd=undef
  else
      getcwd=undef
      getwd=undef
***************
*** 1452,1457
      getcwd=define
  else
      getcwd=undef
  fi
  fi
  

--- 1520,1526 -----
      getwd=undef
  else
      getcwd=undef
+     getwd=undef
  fi
  fi
  
***************
*** 1588,1594
      if $test -d /lib/386 ; then
  	iandd="-M3e"
      else
! 	iandd="-M2let8 -LARGE -F 3000"
      fi
  jobslib=-lx
  fi

--- 1657,1664 -----
      if $test -d /lib/386 ; then
  	iandd="-M3e"
      else
! :	iandd="-M2let8 -LARGE -F 3000"
! 	iandd="-Ml2et32 -LARGE -F B000"
      fi
  jobslib=-lx
  fi
***************
*** 1732,1738
      esac
  
  done
! : hack for Unisys NET-5000
  case "$isrrn" in
  define) 
      if $test -d /usr/include/NET-5000 ; then

--- 1802,1808 -----
      esac
  
  done
! : hack for Unisys NET-5000 and Interactive V/386
  case "$isrrn" in
  define) 
  : NET-5000
***************
*** 1735,1740
  : hack for Unisys NET-5000
  case "$isrrn" in
  define) 
      if $test -d /usr/include/NET-5000 ; then
  	$echo "I sense you are on a Unisys 5000 computer...poor soul."
  	rrninclude="-I/usr/include/NET-5000 -DEXCELAN -DUSG"

--- 1805,1811 -----
  : hack for Unisys NET-5000 and Interactive V/386
  case "$isrrn" in
  define) 
+ : NET-5000
      if $test -d /usr/include/NET-5000 ; then
  	$echo "I sense you are on a Unisys 5000 computer...poor soul."
  	rrninclude="-I/usr/include/NET-5000 -DEXCELAN -DUSG"
***************
*** 1740,1745
  	rrninclude="-I/usr/include/NET-5000 -DEXCELAN -DUSG"
  	socketlib=-lsocket
      fi
      ;;
  *) ;;
  esac

--- 1811,1821 -----
  	rrninclude="-I/usr/include/NET-5000 -DEXCELAN -DUSG"
  	socketlib=-lsocket
      fi
+ : Interactive Unix
+     if $test -f /usr/lib/libinet.a ; then
+ 	rrninclude="-DUSG"
+ 	socketlib=-linet
+     fi
      ;;
  *) ;;
  esac
***************
*** 2278,2283
  jobslib='$jobslib'
  socketlib='$socketlib'
  getcwd='$getcwd'
  dirtype='$dirtype'
  ndirlib='$ndirlib'
  libndir='$libndir'

--- 2354,2360 -----
  jobslib='$jobslib'
  socketlib='$socketlib'
  getcwd='$getcwd'
+ getwd='$getwd'
  dirtype='$dirtype'
  ndirlib='$ndirlib'
  libndir='$libndir'
***************
*** 2316,2321
  cntrypref='$cntrypref'
  contpref='$contpref'
  strchr='$strchr'
  novoid='$novoid'
  novfork='$novfork'
  portable='$portable'

--- 2393,2399 -----
  cntrypref='$cntrypref'
  contpref='$contpref'
  strchr='$strchr'
+ memcpy='$memcpy'
  novoid='$novoid'
  novfork='$novfork'
  portable='$portable'
***************
*** 2326,2331
  termio='$termio'
  fcntl='$fcntl'
  ioctl='$ioctl'
  normsig='$normsig'
  sigblock='$sigblock'
  sigret='$sigret'

--- 2404,2410 -----
  termio='$termio'
  fcntl='$fcntl'
  ioctl='$ioctl'
+ ptem='$ptem'
  normsig='$normsig'
  sigblock='$sigblock'
  sigret='$sigret'
***************
*** 2402,2407
  
  #$strchr	index strchr	/* cultural */
  #$strchr	rindex strrchr	/*  differences? */
  #$novoid	void int	/* is void to be avoided? */
  #$novfork	vfork fork	/* is vfork too virtual? */
  #$eunice	EUNICE		/* no linking? */

--- 2481,2487 -----
  
  #$strchr	index strchr	/* cultural */
  #$strchr	rindex strrchr	/*  differences? */
+ #$memcpy	bcopy(a,b,c)	memcpy(b,a,c)
  #$novoid	void int	/* is void to be avoided? */
  #$novfork	vfork fork	/* is vfork too virtual? */
  #$eunice	EUNICE		/* no linking? */
***************
*** 2407,2412
  #$eunice	EUNICE		/* no linking? */
  #$eunice	VMS		/* not currently used, here just in case */
  #$getcwd	GETCWD		/* do we have getcwd()? */
  #$usendir	USENDIR		/* include ndir.c? */
  #$libndir	LIBNDIR		/* include /usr/include/ndir.h? */
  #define		DIRTYPE   $dirtype

--- 2487,2493 -----
  #$eunice	EUNICE		/* no linking? */
  #$eunice	VMS		/* not currently used, here just in case */
  #$getcwd	GETCWD		/* do we have getcwd()? */
+ #$getwd		GETWD		/* do we have getwd()? */
  #$usendir	USENDIR		/* include ndir.c? */
  #$libndir	LIBNDIR		/* include /usr/include/ndir.h? */
  #define		DIRTYPE   $dirtype
***************
*** 2426,2431
  #$termio	TERMIO		/* is this a termio system? */
  #$fcntl		FCNTL		/* should we include fcntl.h? */
  #$ioctl		IOCTL		/* are ioctl args all defined in one place? */
  #$normsig	NORMSIG		/* use signal rather than sigset? */
  #$sigblock	SIGBLOCK	/* use sigblock and sigsetmask */
  #define	    	SIGRET	$sigret	/* what does signal() return? */

--- 2507,2513 -----
  #$termio	TERMIO		/* is this a termio system? */
  #$fcntl		FCNTL		/* should we include fcntl.h? */
  #$ioctl		IOCTL		/* are ioctl args all defined in one place? */
+ #$ptem		PTEM		/* has the ptem.h include file ? */
  #$normsig	NORMSIG		/* use signal rather than sigset? */
  #$sigblock	SIGBLOCK	/* use sigblock and sigsetmask */
  #define	    	SIGRET	$sigret	/* what does signal() return? */

Index: makedepend.SH
Prereq: 4.3.2.2
*** old/makedepend.SH	Thu Nov  8 02:24:20 1990
--- new/makedepend.SH	Thu Nov  8 02:29:41 1990
***************
*** 4,10
  echo "Extracting makedepend (with variable substitutions)"
  $spitshell >makedepend <<!GROK!THIS!
  $startsh
! # $Header: makedepend.SH,v 4.3.2.2 90/04/21 14:24:58 sob Exp $
  #
  # $Log:	makedepend.SH,v $
  # Revision 4.3.2.2  90/04/21  14:24:58  sob

--- 4,10 -----
  echo "Extracting makedepend (with variable substitutions)"
  $spitshell >makedepend <<!GROK!THIS!
  $startsh
! # $Header: makedepend.SH,v 4.3.2.3 90/10/30 22:46:14 sob Exp $
  #
  # $Log:	makedepend.SH,v $
  # Revision 4.3.2.3  90/10/30  22:46:14  sob
***************
*** 7,12
  # $Header: makedepend.SH,v 4.3.2.2 90/04/21 14:24:58 sob Exp $
  #
  # $Log:	makedepend.SH,v $
  # Revision 4.3.2.2  90/04/21  14:24:58  sob
  # Added a fix to deal with XENIX cc -E output.
  # 

--- 7,15 -----
  # $Header: makedepend.SH,v 4.3.2.3 90/10/30 22:46:14 sob Exp $
  #
  # $Log:	makedepend.SH,v $
+ # Revision 4.3.2.3  90/10/30  22:46:14  sob
+ # Made minor changes to the send command to work better on Apollos.
+ # 
  # Revision 4.3.2.2  90/04/21  14:24:58  sob
  # Added a fix to deal with XENIX cc -E output.
  # 
***************
*** 55,61
  if $test -s .deptmp; then
      echo "Updating Makefile..."
      echo "# If this runs make out of memory, delete /usr/include lines." >>Makefile.new
!     $cat .deptmp >>Makefile.new
  else
      $echo "You don't seem to have a proper C preprocessor.  Using grep instead."
      $egrep '^#include ' *.c *.h >.deptmp

--- 58,64 -----
  if $test -s .deptmp; then
      echo "Updating Makefile..."
      echo "# If this runs make out of memory, delete /usr/include lines." >>Makefile.new
!     $sed -e 's/\\\$/\$\$/g' .deptmp >>Makefile.new
  else
      $echo "You don't seem to have a proper C preprocessor.  Using grep instead."
      $egrep '^#include ' *.c *.h >.deptmp

Index: Pnews.SH
Prereq: 4.3.2.7
*** old/Pnews.SH	Thu Nov  8 02:23:57 1990
--- new/Pnews.SH	Thu Nov  8 02:29:16 1990
***************
*** 1,5
  case $CONFIG in
!     '') . config.sh ;;
  esac
  echo "Extracting Pnews (with variable substitutions)"
  $spitshell >Pnews <<!GROK!THIS!

--- 1,5 -----
  case $CONFIG in
!     '') . ./config.sh ;;
  esac
  echo "Extracting Pnews (with variable substitutions)"
  $spitshell >Pnews <<!GROK!THIS!
***************
*** 4,10
  echo "Extracting Pnews (with variable substitutions)"
  $spitshell >Pnews <<!GROK!THIS!
  $startsh
! # $Header: Pnews.SH,v 4.3.2.7 90/05/04 23:14:45 sob Exp $
  #
  # $Log:	Pnews.SH,v $
  # Revision 4.3.2.7  90/05/04  23:14:45  sob

--- 4,10 -----
  echo "Extracting Pnews (with variable substitutions)"
  $spitshell >Pnews <<!GROK!THIS!
  $startsh
! # $Header: Pnews.SH,v 4.3.2.9 90/11/06 00:54:52 sob Exp $
  #
  # $Log:	Pnews.SH,v $
  # Revision 4.3.2.9  90/11/06  00:54:52  sob
***************
*** 7,12
  # $Header: Pnews.SH,v 4.3.2.7 90/05/04 23:14:45 sob Exp $
  #
  # $Log:	Pnews.SH,v $
  # Revision 4.3.2.7  90/05/04  23:14:45  sob
  # Expires: line removed from Pnews.header.
  # 

--- 7,19 -----
  # $Header: Pnews.SH,v 4.3.2.9 90/11/06 00:54:52 sob Exp $
  #
  # $Log:	Pnews.SH,v $
+ # Revision 4.3.2.9  90/11/06  00:54:52  sob
+ # Added ./ to be beginning of config.sh
+ # 
+ # Revision 4.3.2.8  90/11/06  00:08:11  sob
+ # Fixed bug in sed syntax for usg password file format per bug report by
+ # prc@erbe.se
+ # 
  # Revision 4.3.2.7  90/05/04  23:14:45  sob
  # Expires: line removed from Pnews.header.
  # 
***************
*** 690,696
      ;;
  usg)
   	if $test "$ypmatch" != ""; then
!  		fullname=`$ypmatch $logname passwd 2>/dev/null | $sed "s/^[^:]*:[^:]*:[^:]*:[^:]*:\([^(:]*\).*"'$'"/\1/" -e "s/^.*-//" -e "q"`
   	fi
       if $test "$fullname" = ""; then
      fullname=`$sed </etc/passwd -e "/^$logname:/{s/^[^:]*:[^:]*:[^:]*:[^:]*:\([^(:]*\).*"'$'"/\1/" -e "s/^.*-//" -e "q" -e "}" -e "d"`

--- 697,703 -----
      ;;
  usg)
   	if $test "$ypmatch" != ""; then
!  		fullname=`$ypmatch $logname passwd 2>/dev/null | $sed -e "s/^[^:]*:[^:]*:[^:]*:[^:]*:\([^(:]*\).*"'$'"/\1/" -e "s/^.*-//" -e "q"`
   	fi
       if $test "$fullname" = ""; then
      fullname=`$sed </etc/passwd -e "/^$logname:/{s/^[^:]*:[^:]*:[^:]*:[^:]*:\([^(:]*\).*"'$'"/\1/" -e "s/^.*-//" -e "q" -e "}" -e "d"`

Index: newsnews.SH
*** old/newsnews.SH	Thu Nov  8 02:24:27 1990
--- new/newsnews.SH	Thu Nov  8 02:28:58 1990
***************
*** 1,5
  case $CONFIG in
!     '') . config.sh ;;
  esac
  echo "Extracting newsnews (with variable substitutions)"
  cat >newsnews <<!GROK!THIS!

--- 1,5 -----
  case $CONFIG in
!     '') . ./config.sh ;;
  esac
  echo "Extracting newsnews (with variable substitutions)"
  cat >newsnews <<!GROK!THIS!
***************
*** 19,25
      spend all day reading news and never hit anything but the space bar.
  
  This particular message comes from $rnlib/newsnews.  You will only
! see it once.  You news administrator should feel free to substitute his or
  her own message whenever something new happens to rn, and then the file
  will again be displayed, just once for each person.
  

--- 19,25 -----
      spend all day reading news and never hit anything but the space bar.
  
  This particular message comes from $rnlib/newsnews.  You will only
! see it once.  Your news administrator should feel free to substitute his or
  her own message whenever something new happens to rn, and then the file
  will again be displayed, just once for each person.
  
Index: rn.c
Prereq: 4.3.2.4
*** old/rn.c	Thu Nov  8 02:23:58 1990
--- new/rn.c	Thu Nov  8 02:29:12 1990
***************
*** 9,16
   *      RRN/RN: 11/01/89
  */
  
! static char rnid[] = "@(#)$Header: rn.c,v 4.3.2.4 90/04/03 23:11:33 sob Exp $";
! static char patchlevel[] = "Patch #: 47";
  
  /* $Log:	rn.c,v $
   * Revision 4.3.2.4  90/04/03  23:11:33  sob

--- 9,16 -----
   *      RRN/RN: 11/01/89
  */
  
! static char rnid[] = "@(#)$Header: rn.c,v 4.3.2.5 90/11/06 01:19:43 sob Exp $";
! static char patchlevel[] = "Patch #: 48";
  
  /* $Log:	rn.c,v $
   * Revision 4.3.2.5  90/11/06  01:19:43  sob
***************
*** 13,18
  static char patchlevel[] = "Patch #: 47";
  
  /* $Log:	rn.c,v $
   * Revision 4.3.2.4  90/04/03  23:11:33  sob
   * Added more information to the version command.
   * 

--- 13,21 -----
  static char patchlevel[] = "Patch #: 48";
  
  /* $Log:	rn.c,v $
+  * Revision 4.3.2.5  90/11/06  01:19:43  sob
+  * Checkpoint for patch 48
+  * 
   * Revision 4.3.2.4  90/04/03  23:11:33  sob
   * Added more information to the version command.
   * 
***************
*** 557,560
  	    *s = '/';
      return myngdir;
  }
- 

--- 560,562 -----
  	    *s = '/';
      return myngdir;
  }

Index: rn.1
Prereq: 4.3.1.9
*** old/rn.1	Thu Nov  8 02:23:23 1990
--- new/rn.1	Thu Nov  8 02:28:43 1990
***************
*** 1,4
! ''' $Header: rn.1,v 4.3.1.9 90/05/08 22:05:11 sob Exp $
  ''' 
  ''' $Log:	rn.1,v $
  ''' Revision 4.3.1.9  90/05/08  22:05:11  sob

--- 1,4 -----
! ''' $Header: rn.1,v 4.3.1.10 90/11/06 01:17:29 sob Exp $
  ''' 
  ''' $Log:	rn.1,v $
  ''' Revision 4.3.1.10  90/11/06  01:17:29  sob
***************
*** 1,6
  ''' $Header: rn.1,v 4.3.1.9 90/05/08 22:05:11 sob Exp $
  ''' 
  ''' $Log:	rn.1,v $
  ''' Revision 4.3.1.9  90/05/08  22:05:11  sob
  ''' Added documentation for new -q flag
  ''' 

--- 1,9 -----
  ''' $Header: rn.1,v 4.3.1.10 90/11/06 01:17:29 sob Exp $
  ''' 
  ''' $Log:	rn.1,v $
+ ''' Revision 4.3.1.10  90/11/06  01:17:29  sob
+ ''' Added text about new Y response when adding newsgroups.
+ ''' 
  ''' Revision 4.3.1.9  90/05/08  22:05:11  sob
  ''' Added documentation for new -q flag
  ''' 
***************
*** 290,296
  file, whether subscribed to or
  not, will not be listed.
  If any new newsgroups are found, you will be asked for each one whether
! you would like to add it.
  After any new newsgroups have been added, the \*(L'a\*(R' command also
  restricts the current set of newsgroups just like the \*(L'o\*(R' command
  does.

--- 293,302 -----
  file, whether subscribed to or
  not, will not be listed.
  If any new newsgroups are found, you will be asked for each one whether
! you would like to add it. If you want to add all new newsgroups, you can
! type  \*(L'Y\*(R' and they will be added the the end of the
! .I .newsrc
! file.
  After any new newsgroups have been added, the \*(L'a\*(R' command also
  restricts the current set of newsgroups just like the \*(L'o\*(R' command
  does.

Index: common.h
Prereq: 4.3.2.13
*** old/common.h	Thu Nov  8 03:03:41 1990
--- new/common.h	Sat Nov 10 00:08:57 1990
***************
*** 1,4
! /* $Header: common.h,v 4.3.2.13 90/05/08 22:05:37 sob Exp $
   * 
   * $Log:	common.h,v $
   * Revision 4.3.2.13  90/05/08  22:05:37  sob

--- 1,4 -----
! /* $Header: common.h,v 4.3.2.19 90/11/09 23:15:12 sob Exp $
   * 
   * $Log:	common.h,v $
   * Revision 4.3.2.19  90/11/09  23:15:12  sob
***************
*** 1,6
  /* $Header: common.h,v 4.3.2.13 90/05/08 22:05:37 sob Exp $
   * 
   * $Log:	common.h,v $
   * Revision 4.3.2.13  90/05/08  22:05:37  sob
   * Added quick startup (-q) flag.
   * 

--- 1,25 -----
  /* $Header: common.h,v 4.3.2.19 90/11/09 23:15:12 sob Exp $
   * 
   * $Log:	common.h,v $
+  * Revision 4.3.2.19  90/11/09  23:15:12  sob
+  * Added sys/stream.h since sys/ptem.h depends on it.
+  * 
+  * Revision 4.3.2.18  90/11/06  00:11:04  sob
+  * Attempt to deal with USG C compilers that can't cope with mutiple
+  * includes of the same include file.
+  * 
+  * Revision 4.3.2.17  90/11/05  23:29:37  sob
+  * Added the include of /usr/include/sys/ptem.h if defined in config.h.
+  * 
+  * Revision 4.3.2.16  90/11/04  03:34:32  sob
+  * Changed and moved GETWD to Configure.
+  * 
+  * Revision 4.3.2.15  90/10/01  02:07:36  sob
+  * Increased LBUFLEN from 512 to 1024 per request of ken@csis.dit.csiro.au.
+  * 
+  * Revision 4.3.2.14  90/10/01  01:56:06  sob
+  * Fixed problem with the call to MBOXSAVER reported by news@twwells.com.
+  * 
   * Revision 4.3.2.13  90/05/08  22:05:37  sob
   * Added quick startup (-q) flag.
   * 
***************
*** 66,71
  
  #include <stdio.h>
  #include <sys/types.h>
  #include <sys/stat.h>
  #include <ctype.h>
  

--- 85,91 -----
  
  #include <stdio.h>
  #include <sys/types.h>
+ #define _SYS_TYPES.H		/* For some ANSI C compilers */
  #include <sys/stat.h>
  #include <ctype.h>
  
***************
*** 93,98
  #   include <pwd.h>
  #endif
  
  #define BITSPERBYTE 8
  #define LBUFLEN 512	/* line buffer length */
  			/* (don't worry, .newsrc lines can exceed this) */

--- 113,123 -----
  #   include <pwd.h>
  #endif
  
+ #ifdef PTEM
+ #include <sys/stream.h>
+ #include <sys/ptem.h>
+ #endif
+ 
  #define BITSPERBYTE 8
  #ifdef pdp11
  #define LBUFLEN 512	/* line buffer length */
***************
*** 94,99
  #endif
  
  #define BITSPERBYTE 8
  #define LBUFLEN 512	/* line buffer length */
  			/* (don't worry, .newsrc lines can exceed this) */
  #ifdef pdp11

--- 119,125 -----
  #endif
  
  #define BITSPERBYTE 8
+ #ifdef pdp11
  #define LBUFLEN 512	/* line buffer length */
  #else
  #define LBUFLEN 1024	/* line buffer length */
***************
*** 95,100
  
  #define BITSPERBYTE 8
  #define LBUFLEN 512	/* line buffer length */
  			/* (don't worry, .newsrc lines can exceed this) */
  #ifdef pdp11
  #   define CBUFLEN 256	/* command buffer length */

--- 121,129 -----
  #define BITSPERBYTE 8
  #ifdef pdp11
  #define LBUFLEN 512	/* line buffer length */
+ #else
+ #define LBUFLEN 1024	/* line buffer length */
+ #endif
  			/* (don't worry, .newsrc lines can exceed this) */
  #ifdef pdp11
  #   define CBUFLEN 256	/* command buffer length */
***************
*** 286,292
  #define ORGFILE		/* if organization begins with /, look up in file */
  #define TILDENAME	/* allow ~logname expansion */
  #define SETENV		/* allow command line environment variable setting */
- #define GETWD		/* use our getwd() instead of piped in pwd */
  #define MAKEDIR		/* use our makedir() instead of shell script */
  #define MEMHELP		/* keep help messages in memory */
  #define VERBOSE		/* compile in more informative messages */

--- 315,320 -----
  #define ORGFILE		/* if organization begins with /, look up in file */
  #define TILDENAME	/* allow ~logname expansion */
  #define SETENV		/* allow command line environment variable setting */
  #define MAKEDIR		/* use our makedir() instead of shell script */
  #define MEMHELP		/* keep help messages in memory */
  #define VERBOSE		/* compile in more informative messages */
***************
*** 640,646
  #	ifdef CONDSUB
  #           ifdef SERVER
  #               define MBOXSAVER "%X/mbox.saver %P/rrn%a.%$ %P %c %a %B %C \"%b\
! " \"From %T %(%[date]=^\\(\\w*\\), \\(\\w*\\)-\\(\\w*\\)-\\(\\w*\\) \\([^ ]*\\)?
  %1 %3 %(%2=..?%2: %2) %5 19%4)\""
  #           else
  #	        define MBOXSAVER "%X/mbox.saver %A %P %c %a %B %C \"%b\" \"From %T %(%[date]=^\\(\\w*\\), \\(\\w*\\)-\\(\\w*\\)-\\(\\w*\\) \\([^ ]*\\)?%1 %3 %(%2=..?%2: %2) %5 19%4)\""

--- 668,674 -----
  #	ifdef CONDSUB
  #           ifdef SERVER
  #               define MBOXSAVER "%X/mbox.saver %P/rrn%a.%$ %P %c %a %B %C \"%b\
!  \"From %T %(%[date]=^\\(\\w*\\), \\(\\w*\\)-\\(\\w*\\)-\\(\\w*\\) \\([^ ]*\\)?
  %1 %3 %(%2=..?%2: %2) %5 19%4)\""
  #           else
  #	        define MBOXSAVER "%X/mbox.saver %A %P %c %a %B %C \"%b\" \"From %T %(%[date]=^\\(\\w*\\), \\(\\w*\\)-\\(\\w*\\)-\\(\\w*\\) \\([^ ]*\\)?%1 %3 %(%2=..?%2: %2) %5 19%4)\""

Index: term.h
Prereq: 4.3.2.2
*** old/term.h	Thu Nov  8 02:24:08 1990
--- new/term.h	Thu Nov  8 02:29:27 1990
***************
*** 1,4
! /* $Header: term.h,v 4.3.2.2 90/04/06 20:35:34 sob Exp $
   *
   * $Log:	term.h,v $
   * Revision 4.3.2.2  90/04/06  20:35:34  sob

--- 1,4 -----
! /* $Header: term.h,v 4.3.2.4 90/11/05 23:54:49 sob Exp $
   *
   * $Log:	term.h,v $
   * Revision 4.3.2.4  90/11/05  23:54:49  sob
***************
*** 1,6
  /* $Header: term.h,v 4.3.2.2 90/04/06 20:35:34 sob Exp $
   *
   * $Log:	term.h,v $
   * Revision 4.3.2.2  90/04/06  20:35:34  sob
   * Added fixes for SCO Xenix sent by ronald@robobar.co.uk.
   * 

--- 1,12 -----
  /* $Header: term.h,v 4.3.2.4 90/11/05 23:54:49 sob Exp $
   *
   * $Log:	term.h,v $
+  * Revision 4.3.2.4  90/11/05  23:54:49  sob
+  * changed maybe_eol to test when erase_screen is FALSE intstead of TRUE.
+  * 
+  * Revision 4.3.2.3  90/10/01  01:49:39  sob
+  * Changed ospeed from short to long.
+  * 
   * Revision 4.3.2.2  90/04/06  20:35:34  sob
   * Added fixes for SCO Xenix sent by ronald@robobar.co.uk.
   * 
***************
*** 158,166
  EXT char *CL INIT(Nullch);		/* home and clear screen */
  EXT char *CE INIT(Nullch);		/* clear to end of line */
  #ifdef CLEAREOL
! EXT char *CM INIT(Nullch);		/* cursor motion -- PWP */
! EXT char *HO INIT(Nullch);		/* home cursor -- PWP */
! EXT char *CD INIT(Nullch);		/* clear to end of display -- PWP */
  #endif CLEAREOL
  EXT char *SO INIT(Nullch);		/* begin standout mode */
  EXT char *SE INIT(Nullch);		/* end standout mode */

--- 164,172 -----
  EXT char *CL INIT(Nullch);		/* home and clear screen */
  EXT char *CE INIT(Nullch);		/* clear to end of line */
  #ifdef CLEAREOL
! EXT char *CM INIT(Nullch);		/* cursor motion */
! EXT char *HO INIT(Nullch);		/* home cursor */
! EXT char *CD INIT(Nullch);		/* clear to end of display */
  #endif CLEAREOL
  EXT char *SO INIT(Nullch);		/* begin standout mode */
  EXT char *SE INIT(Nullch);		/* end standout mode */
***************
*** 172,178
  EXT bool AM INIT(FALSE);		/* does terminal have automatic margins? */
  EXT bool XN INIT(FALSE);		/* does it eat 1st newline after automatic wrap? */
  EXT char PC INIT(0);		/* pad character for use by tputs() */
! EXT short ospeed INIT(0);	/* terminal output speed, for use by tputs() */
  EXT int LINES INIT(0), COLS INIT(0);	/* size of screen */
  EXT int just_a_sec INIT(960);			/* 1 sec at current baud rate */
  					/* (number of nulls) */

--- 178,184 -----
  EXT bool AM INIT(FALSE);		/* does terminal have automatic margins? */
  EXT bool XN INIT(FALSE);		/* does it eat 1st newline after automatic wrap? */
  EXT char PC INIT(0);		/* pad character for use by tputs() */
! EXT long ospeed INIT(0);	/* terminal output speed, for use by tputs() */
  EXT int LINES INIT(0), COLS INIT(0);	/* size of screen */
  EXT int just_a_sec INIT(960);			/* 1 sec at current baud rate */
  					/* (number of nulls) */
***************
*** 183,190
  #define clear() tputs(CL,LINES,putchr) FLUSH
  #define erase_eol() tputs(CE,1,putchr) FLUSH
  #ifdef CLEAREOL
! #define clear_rest() tputs(CD,LINES,putchr) FLUSH	/* PWP */
! #define maybe_eol() if(erase_screen&&can_home_clear)tputs(CE,1,putchr) FLUSH
  #endif CLEAREOL
  #define underline() tputs(US,1,putchr) FLUSH
  #define un_underline() tputs(UE,1,putchr) FLUSH

--- 189,196 -----
  #define clear() tputs(CL,LINES,putchr) FLUSH
  #define erase_eol() tputs(CE,1,putchr) FLUSH
  #ifdef CLEAREOL
! #define clear_rest() tputs(CD,LINES,putchr) FLUSH
! #define maybe_eol() if(!erase_screen&&can_home_clear)tputs(CE,1,putchr) FLUSH
  #endif CLEAREOL
  #define underline() tputs(US,1,putchr) FLUSH
  #define un_underline() tputs(UE,1,putchr) FLUSH

Index: term.c
Prereq: 4.3.2.7
*** old/term.c	Thu Nov  8 02:23:44 1990
--- new/term.c	Thu Nov  8 02:29:04 1990
***************
*** 1,4
! /* $Header: term.c,v 4.3.2.7 90/04/21 16:54:29 sob Exp $
   *
   * $Log:	term.c,v $
   * Revision 4.3.2.7  90/04/21  16:54:29  sob

--- 1,4 -----
! /* $Header: term.c,v 4.3.2.10 90/11/05 23:41:29 sob Exp $
   *
   * $Log:	term.c,v $
   * Revision 4.3.2.10  90/11/05  23:41:29  sob
***************
*** 1,6
  /* $Header: term.c,v 4.3.2.7 90/04/21 16:54:29 sob Exp $
   *
   * $Log:	term.c,v $
   * Revision 4.3.2.7  90/04/21  16:54:29  sob
   * Installed patches provided by SCO for SCO Xenix
   * 

--- 1,15 -----
  /* $Header: term.c,v 4.3.2.10 90/11/05 23:41:29 sob Exp $
   *
   * $Log:	term.c,v $
+  * Revision 4.3.2.10  90/11/05  23:41:29  sob
+  * Now it's gone.
+  * 
+  * Revision 4.3.2.9  90/11/05  23:30:07  sob
+  * moved the winsize struct in anticipation of removing it.
+  * 
+  * Revision 4.3.2.8  90/10/01  01:43:59  sob
+  * Fixed syntax error pointed out by stealth@m-net.ann-arbor.mi.us.
+  * 
   * Revision 4.3.2.7  90/04/21  16:54:29  sob
   * Installed patches provided by SCO for SCO Xenix
   * 
***************
*** 146,159
      char *s;
      int status;
  #ifdef TIOCGWINSZ
- #ifdef u3b2
- struct winsize {
- 	unsigned short ws_row;       /* rows, in characters*/
- 	unsigned short ws_col;       /* columns, in character */
- 	unsigned short ws_xpixel;    /* horizontal size, pixels */
- 	unsigned short ws_ypixel;    /* vertical size, pixels */
- };
- #endif
      struct winsize winsize;
  #endif
  

--- 155,160 -----
      char *s;
      int status;
  #ifdef TIOCGWINSZ
      struct winsize winsize;
  #endif
  
***************
*** 178,184
  #ifdef VERBOSE
  	printf("No termcap %s found.\n", status ? "file" : "entry") FLUSH;
  #else
! 	fputs("Termcap botch\n",stdout) FLUSH
  #endif
  	finalize(1);
      }

--- 179,185 -----
  #ifdef VERBOSE
  	printf("No termcap %s found.\n", status ? "file" : "entry") FLUSH;
  #else
! 	fputs("Termcap botch\n",stdout) FLUSH;
  #endif
  	finalize(1);
      }

Index: addng.c
Prereq: 4.3.2.4
*** old/addng.c	Thu Nov  8 02:23:24 1990
--- new/addng.c	Thu Nov  8 02:29:35 1990
***************
*** 1,4
! /* $Header: addng.c,v 4.3.2.4 90/03/17 17:11:36 sob Exp $
   *
   * $Log:	addng.c,v $
   * Revision 4.3.2.4  90/03/17  17:11:36  sob

--- 1,4 -----
! /* $Header: addng.c,v 4.3.2.5 90/09/04 23:29:51 sob Exp $
   *
   * $Log:	addng.c,v $
   * Revision 4.3.2.5  90/09/04  23:29:51  sob
***************
*** 1,6
  /* $Header: addng.c,v 4.3.2.4 90/03/17 17:11:36 sob Exp $
   *
   * $Log:	addng.c,v $
   * Revision 4.3.2.4  90/03/17  17:11:36  sob
   * Added support for CNEWS active file flags.
   * 

--- 1,9 -----
  /* $Header: addng.c,v 4.3.2.5 90/09/04 23:29:51 sob Exp $
   *
   * $Log:	addng.c,v $
+  * Revision 4.3.2.5  90/09/04  23:29:51  sob
+  * Added fix for bithof() from bug report by kwthomas@nsslsun.gcn.uoknor.edu
+  * 
   * Revision 4.3.2.4  90/03/17  17:11:36  sob
   * Added support for CNEWS active file flags.
   * 
***************
*** 4,12
   * Revision 4.3.2.4  90/03/17  17:11:36  sob
   * Added support for CNEWS active file flags.
   * 
-  * Revision 4.3.2.4  89/12/20  00:30:00  tale
-  * Added support for C News active file flags.
-  *
   * Revision 4.3.2.3  89/11/08  02:33:28  sob
   * Added include for server.h
   * 

--- 7,12 -----
   * Revision 4.3.2.4  90/03/17  17:11:36  sob
   * Added support for CNEWS active file flags.
   * 
   * Revision 4.3.2.3  89/11/08  02:33:28  sob
   * Added include for server.h
   * 
***************
*** 133,146
   
  #ifdef SERVER
      int x,tot,min,max;
!     if (ngsize < 2) {
!           sprintf(tst,"GROUP %s",ngnam);
!           put_server(tst);
!           (void) get_server(tst, sizeof(tst));
!           if (*tst != CHAR_OK) return(0); /* not a real group */
!           (void) sscanf(tst,"%d%d%d%d",&x,&tot,&min,&max);
!           if (tot == 1 && min == 1 && max == 1) return(time(Null(long *)));
!      } else return(0);
  #else not SERVER
  
      sprintf(tst, ngsize ? "%s/%s/1" : "%s/%s" ,spool,getngdir(ngnam));

--- 133,145 -----
   
  #ifdef SERVER
      int x,tot,min,max;
!     sprintf(tst,"GROUP %s",ngnam);
!     put_server(tst);
!     (void) get_server(tst, sizeof(tst));
!     if (*tst != CHAR_OK) return(0); /* not a real group */
!     (void) sscanf(tst,"%d%d%d%d",&x,&tot,&min,&max);
!     if (tot > 0) return(time(Null(long *)));
!     else return(0);
  #else not SERVER
  
      sprintf(tst, ngsize ? "%s/%s/1" : "%s/%s" ,spool,getngdir(ngnam));

Index: art.c
Prereq: 4.3.2.3
*** old/art.c	Thu Nov  8 02:23:50 1990
--- new/art.c	Thu Nov  8 02:29:11 1990
***************
*** 1,4
! /* $Header: art.c,v 4.3.2.3 90/04/21 14:43:27 sob Exp $
   *
   * $Log:	art.c,v $
   * Revision 4.3.2.3  90/04/21  14:43:27  sob

--- 1,4 -----
! /* $Header: art.c,v 4.3.2.6 90/10/01 21:14:36 sob Exp $
   *
   * $Log:	art.c,v $
   * Revision 4.3.2.6  90/10/01  21:14:36  sob
***************
*** 1,6
  /* $Header: art.c,v 4.3.2.3 90/04/21 14:43:27 sob Exp $
   *
   * $Log:	art.c,v $
   * Revision 4.3.2.3  90/04/21  14:43:27  sob
   * Revised previous patch insure that it does not decrement below zero.
   * 

--- 1,16 -----
  /* $Header: art.c,v 4.3.2.6 90/10/01 21:14:36 sob Exp $
   *
   * $Log:	art.c,v $
+  * Revision 4.3.2.6  90/10/01  21:14:36  sob
+  * Shifted to fileno to increase portability.
+  * 
+  * Revision 4.3.2.5  90/10/01  21:05:22  sob
+  * Removed an extra closing paren.
+  * 
+  * Revision 4.3.2.4  90/10/01  02:01:53  sob
+  * Fix provided by earle@sun.com to alter rn's assumption of how to turn
+  * off underline mode when at the end of a line.
+  * 
   * Revision 4.3.2.3  90/04/21  14:43:27  sob
   * Revised previous patch insure that it does not decrement below zero.
   * 
***************
*** 110,116
      register int outputok;
  #endif
  
!     if (fstat(artfp->_file,&filestat))
  			    /* get article file stats */
  	return DA_CLEAN;
      if ((filestat.st_mode & S_IFMT) != S_IFREG)

--- 120,127 -----
      register int outputok;
  #endif
  
! /*  if (fstat(artfp->_file,&filestat)) ... does not work on Apollos */
!     if (fstat(fileno(artfp),&filestat))
  			    /* get article file stats */
  	return DA_CLEAN;
      if ((filestat.st_mode & S_IFMT) != S_IFREG)
***************
*** 162,168
  		if (i || dmcount) {
  		    printf(" (%ld more",(long)i);
  		    if (dmcount)
! 			printf(" + %ld Marked to return)",(long)dmcount);
  		    putchar(')');
  		}
  #else

--- 173,179 -----
  		if (i || dmcount) {
  		    printf(" (%ld more",(long)i);
  		    if (dmcount)
! 			printf(" + %ld Marked to return",(long)dmcount);
  		    putchar(')');
  		}
  #else
***************
*** 395,400
  #ifdef INNERSEARCH
  			if (outputok)
  #endif
  			    putchar('\n') FLUSH;
  			restart = 0;
  			outpos = 1000;	/* signal normal \n */

--- 406,422 -----
  #ifdef INNERSEARCH
  			if (outputok)
  #endif
+ 			{
+ 			    /* handle normal end of output line formalities */
+ 
+ 			    if (highlight == artline) {
+ 						/* were we highlighting line? */
+ 		    		if (marking == STANDOUT)
+ 				    un_standout();
+ 		    	    	else
+ 				    un_underline();
+ 		    		highlight = -1;	/* no more we are */
+ 			    }
  			    putchar('\n') FLUSH;
  			}
  			restart = 0;
***************
*** 396,401
  			if (outputok)
  #endif
  			    putchar('\n') FLUSH;
  			restart = 0;
  			outpos = 1000;	/* signal normal \n */
  		    }

--- 418,424 -----
  		    		highlight = -1;	/* no more we are */
  			    }
  			    putchar('\n') FLUSH;
+ 			}
  			restart = 0;
  			outpos = 1000;	/* signal normal \n */
  		    }
***************
*** 470,485
  #endif CLEAREOL
  		}
  
- 		/* handle normal end of output line formalities */
- 
- 		if (highlight == artline) {
- 					/* were we highlighting line? */
- 		    if (marking == STANDOUT)
- 			un_standout();
- 		    else
- 			un_underline();
- 		    highlight = -1;	/* no more we are */
- 		}
  		artline++;	/* count the line just printed */
  		if (artline - LINES + 1 > topline)
  			    /* did we just scroll top line off? */

--- 493,498 -----
  #endif CLEAREOL
  		}
  
  		artline++;	/* count the line just printed */
  		if (artline - LINES + 1 > topline)
  			    /* did we just scroll top line off? */

Index: bits.c
Prereq: 4.3.2.3
*** old/bits.c	Thu Nov  8 02:23:53 1990
--- new/bits.c	Thu Nov  8 02:29:17 1990
***************
*** 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,4 -----
! /* $Header: bits.c,v 4.3.2.4 90/10/06 11:55:33 sob Exp $
   *
   * $Log:	bits.c,v $
   * Revision 4.3.2.4  90/10/06  11:55:33  sob
***************
*** 1,6
  /* $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.
   * 

--- 1,9 -----
  /* $Header: bits.c,v 4.3.2.4 90/10/06 11:55:33 sob Exp $
   *
   * $Log:	bits.c,v $
+  * Revision 4.3.2.4  90/10/06  11:55:33  sob
+  * Added fix for DBM support.
+  * 
   * Revision 4.3.2.3  89/11/28  01:52:02  sob
   * Removed some lint.
   * 
***************
*** 336,341
  	static char *inews_site = Nullch;
  	register ART_NUM x;
  	char tmpbuf[128];
  
  #ifdef DBM
  	rver_buf = fetchlines(artnum,NGS_LINE);

--- 339,345 -----
  	static char *inews_site = Nullch;
  	register ART_NUM x;
  	char tmpbuf[128];
+ 	long pos;
  
  #ifdef DBM
  	rver_buf = fetchlines(artnum,NGS_LINE);
***************
*** 367,374
  	rhs = fetch(lhs);		/* fetch the record */
  	if (rhs.dptr == NULL)		/* if null, nothing there */
  	    goto wild_goose;
! 	fseek (hist_file, *((long *)rhs.dptr), 0);
! 					/* datum returned is position in hist file */
  	fgets (xref_buf, BUFSIZ, hist_file);
  #ifdef DEBUGGING
  	if (debug)

--- 371,379 -----
  	rhs = fetch(lhs);		/* fetch the record */
  	if (rhs.dptr == NULL)		/* if null, nothing there */
  	    goto wild_goose;
! 	bcopy((void *)rhs.dptr,(void *)&pos, 4);
! 	fseek (hist_file, pos, 0);
! 				/* datum returned is position in hist file */
  	fgets (xref_buf, BUFSIZ, hist_file);
  #ifdef DEBUGGING
  	if (debug)

Index: head.c
Prereq: 4.3.2.5
*** old/head.c	Thu Nov  8 02:24:05 1990
--- new/head.c	Thu Nov  8 02:29:24 1990
***************
*** 1,4
! /* $Header: head.c,v 4.3.2.5 90/03/22 23:04:22 sob Exp $
   *
   * $Log:	head.c,v $
   * Revision 4.3.2.5  90/03/22  23:04:22  sob

--- 1,4 -----
! /* $Header: head.c,v 4.3.2.6 90/10/01 01:59:10 sob Exp $
   *
   * $Log:	head.c,v $
   * Revision 4.3.2.6  90/10/01  01:59:10  sob
***************
*** 1,6
  /* $Header: head.c,v 4.3.2.5 90/03/22 23:04:22 sob Exp $
   *
   * $Log:	head.c,v $
   * Revision 4.3.2.5  90/03/22  23:04:22  sob
   * Fixes provided by Wayne Davison <drivax!davison>
   * 

--- 1,9 -----
  /* $Header: head.c,v 4.3.2.6 90/10/01 01:59:10 sob Exp $
   *
   * $Log:	head.c,v $
+  * Revision 4.3.2.6  90/10/01  01:59:10  sob
+  * Fixed possible core dump problem reported by geoff@desint.uucp
+  * 
   * Revision 4.3.2.5  90/03/22  23:04:22  sob
   * Fixes provided by Wayne Davison <drivax!davison>
   * 
***************
*** 372,381
  	    break;
  	if (*tmp_buf == ' ' || *tmp_buf == '\t')
  	    t = tmp_buf;
- 	else
- 	    t = index(tmp_buf,':')+1;
- 	if (t == Nullch)
- 	    break;
  	else {
  	    while (*t == ' ' || *t == '\t') t++;
  	    safecat(newbuf,t,size);

--- 375,380 -----
  	    break;
  	if (*tmp_buf == ' ' || *tmp_buf == '\t')
  	    t = tmp_buf;
  	else {
  	    t = index(tmp_buf,':');
  	    if (t == Nullch)
***************
*** 377,384
  	if (t == Nullch)
  	    break;
  	else {
! 	    while (*t == ' ' || *t == '\t') t++;
! 	    safecat(newbuf,t,size);
  	}
      }
      return newbuf;

--- 376,385 -----
  	if (*tmp_buf == ' ' || *tmp_buf == '\t')
  	    t = tmp_buf;
  	else {
! 	    t = index(tmp_buf,':');
! 	    if (t == Nullch)
! 		break;
! 	    t++;
  	}
  	while (*t == ' ' || *t == '\t') t++;
  	safecat(newbuf,t,size);
***************
*** 380,385
  	    while (*t == ' ' || *t == '\t') t++;
  	    safecat(newbuf,t,size);
  	}
      }
      return newbuf;
  }

--- 381,388 -----
  		break;
  	    t++;
  	}
+ 	while (*t == ' ' || *t == '\t') t++;
+ 	safecat(newbuf,t,size);
      }
      return newbuf;
  }


Index: init.c
Prereq: 4.3.2.6
*** old/init.c	Thu Nov  8 02:24:06 1990
--- new/init.c	Thu Nov  8 02:29:25 1990
***************
*** 1,4
! /* $Header: init.c,v 4.3.2.6 90/05/08 22:05:55 sob Exp $
   *
   * $Log:	init.c,v $
   * Revision 4.3.2.6  90/05/08  22:05:55  sob

--- 1,4 -----
! /* $Header: init.c,v 4.3.2.7 90/10/30 22:42:23 sob Exp $
   *
   * $Log:	init.c,v $
   * Revision 4.3.2.7  90/10/30  22:42:23  sob
***************
*** 1,6
  /* $Header: init.c,v 4.3.2.6 90/05/08 22:05:55 sob Exp $
   *
   * $Log:	init.c,v $
   * Revision 4.3.2.6  90/05/08  22:05:55  sob
   * Added quick startup (-q) flag.
   * 

--- 1,9 -----
  /* $Header: init.c,v 4.3.2.7 90/10/30 22:42:23 sob Exp $
   *
   * $Log:	init.c,v $
+  * Revision 4.3.2.7  90/10/30  22:42:23  sob
+  * Used fileno() instead of _file to increase portability.
+  * 
   * Revision 4.3.2.6  90/05/08  22:05:55  sob
   * Added quick startup (-q) flag.
   * 
***************
*** 208,214
      util_init();
  
  #ifdef FINDNEWNG
!     fstat(actfp->_file,&filestat);	/* did active file grow? */
  	/*
  	 * Skip this check if the -q flag was given.
  	 */

--- 211,218 -----
      util_init();
  
  #ifdef FINDNEWNG
! /*  fstat(actfp->_file,&filestat);	... does not work on Apollos */
!     fstat(fileno(actfp),&filestat);	/* did active file grow? */
  	/*
  	 * Skip this check if the -q flag was given.
  	 */
***************
*** 350,356
      char *newsnewsname = filexp(NEWSNEWSNAME);
  
      if ((tmpfp = fopen(newsnewsname,"r")) != Nullfp) {
! 	fstat(tmpfp->_file,&filestat);
  	if (filestat.st_mtime > lasttime) {
  	    while (fgets(buf,sizeof(buf),tmpfp) != Nullch)
  		fputs(buf,stdout) FLUSH;

--- 354,361 -----
      char *newsnewsname = filexp(NEWSNEWSNAME);
  
      if ((tmpfp = fopen(newsnewsname,"r")) != Nullfp) {
! /*	fstat(tmpfp->_file,&filestat);   .... does not work on Apollos */
! 	fstat(fileno(tmpfp),&filestat);
  	if (filestat.st_mtime > lasttime) {
  	    while (fgets(buf,sizeof(buf),tmpfp) != Nullch)
  		fputs(buf,stdout) FLUSH;

Index: intrp.c
Prereq: 4.3.2.4
*** old/intrp.c	Thu Nov  8 02:23:42 1990
--- new/intrp.c	Thu Nov  8 02:28:56 1990
***************
*** 1,4
! /* $Header: intrp.c,v 4.3.2.4 90/04/23 00:31:20 sob Exp $
   *
   * $Log:	intrp.c,v $
   * Revision 4.3.2.4  90/04/23  00:31:20  sob

--- 1,4 -----
! /* $Header: intrp.c,v 4.3.2.7 90/11/05 23:59:33 sob Exp $
   *
   * $Log:	intrp.c,v $
   * Revision 4.3.2.7  90/11/05  23:59:33  sob
***************
*** 1,6
  /* $Header: intrp.c,v 4.3.2.4 90/04/23 00:31:20 sob Exp $
   *
   * $Log:	intrp.c,v $
   * Revision 4.3.2.4  90/04/23  00:31:20  sob
   * Removed unneeded atoi call.
   * 

--- 1,16 -----
  /* $Header: intrp.c,v 4.3.2.7 90/11/05 23:59:33 sob Exp $
   *
   * $Log:	intrp.c,v $
+  * Revision 4.3.2.7  90/11/05  23:59:33  sob
+  * moved the definition of tmpbuf such that it get defined before it is used.
+  * 
+  * Revision 4.3.2.6  90/11/03  18:52:31  sob
+  * Fixed bug in the definition of the nodename using the uname() system call.
+  * 
+  * Revision 4.3.2.5  90/10/01  01:31:18  sob
+  * Fixed problem with struct utsname reported by jrallen@devildog.att.com
+  * when rn is compiled on the Amdahl 5890 UTS 2.0 system.
+  * 
   * Revision 4.3.2.4  90/04/23  00:31:20  sob
   * Removed unneeded atoi call.
   * 
***************
*** 61,67
  #else !GETHOSTNAME
  #   ifdef DOUNAME
  #	include <sys/utsname.h>
! 	struct utsname uts;
  #	undef SITENAME
  #	define SITENAME uts.nodename
  #   else !DOUNAME

--- 71,77 -----
  #else !GETHOSTNAME
  #   ifdef DOUNAME
  #	include <sys/utsname.h>
! 	struct utsname utsn;
  #	undef SITENAME
  #	define SITENAME utsn.nodename
  #   else !DOUNAME
***************
*** 63,69
  #	include <sys/utsname.h>
  	struct utsname uts;
  #	undef SITENAME
! #	define SITENAME uts.nodename
  #   else !DOUNAME
  #	ifdef PHOSTNAME
  	    char *hostname;

--- 73,79 -----
  #	include <sys/utsname.h>
  	struct utsname utsn;
  #	undef SITENAME
! #	define SITENAME utsn.nodename
  #   else !DOUNAME
  #	ifdef PHOSTNAME
  	    char *hostname;
***************
*** 144,150
  #else
  #ifdef DOUNAME
      /* get sysname */
!     uname(&uts);
  #else
  #ifdef PHOSTNAME
      {

--- 154,160 -----
  #else
  #ifdef DOUNAME
      /* get sysname */
!     uname(&utsn);
  #else
  #ifdef PHOSTNAME
      {
***************
*** 1023,1028
  int uid;
  {
      char *s, *c;
  
  #ifdef PASSNAMES
  #ifdef GETPWENT

--- 1033,1039 -----
  int uid;
  {
      char *s, *c;
+     char tmpbuf[512];
  
  #ifdef PASSNAMES
  #ifdef GETPWENT
***************
*** 1030,1036
      
      s = pwd->pw_gecos;
  #else
-     char tmpbuf[512];
      int i;
  
      getpw(uid, tmpbuf);

--- 1041,1046 -----
      
      s = pwd->pw_gecos;
  #else
      int i;
  
      getpw(uid, tmpbuf);
***************
*** 1087,1089
      fputs("\n% interp buffer overflow!\n",stdout) FLUSH;
      sig_catcher(0);
  }

--- 1097,1101 -----
      fputs("\n% interp buffer overflow!\n",stdout) FLUSH;
      sig_catcher(0);
  }
+ 
+ 

Index: rcstuff.c
Prereq: 4.3.2.5
*** old/rcstuff.c	Thu Nov  8 02:23:52 1990
--- new/rcstuff.c	Thu Nov  8 02:29:09 1990
***************
*** 1,4
! /* $Header: rcstuff.c,v 4.3.2.5 90/05/04 00:44:07 sob Exp $
   *
   * $Log:	rcstuff.c,v $
   * Revision 4.3.2.5  90/05/04  00:44:07  sob

--- 1,4 -----
! /* $Header: rcstuff.c,v 4.3.2.9 90/11/06 01:04:39 sob Exp $
   *
   * $Log:	rcstuff.c,v $
   * Revision 4.3.2.9  90/11/06  01:04:39  sob
***************
*** 1,6
  /* $Header: rcstuff.c,v 4.3.2.5 90/05/04 00:44:07 sob Exp $
   *
   * $Log:	rcstuff.c,v $
   * Revision 4.3.2.5  90/05/04  00:44:07  sob
   * Fixes to add_newsgroup() from lar@usl.edu.
   * 

--- 1,19 -----
  /* $Header: rcstuff.c,v 4.3.2.9 90/11/06 01:04:39 sob Exp $
   *
   * $Log:	rcstuff.c,v $
+  * Revision 4.3.2.9  90/11/06  01:04:39  sob
+  * Updated help messages to include new Y command when adding new newsgroups.
+  * 
+  * Revision 4.3.2.8  90/10/30  23:26:43  sob
+  * Changes to restore .newsrc when exiting rn and diskspace runs out while
+  * updating .newsrc.
+  * 
+  * Revision 4.3.2.7  90/10/30  22:47:49  sob
+  * A bit of cleanup.
+  * 
+  * Revision 4.3.2.6  90/09/04  23:36:32  sob
+  * Changed "add" to "subscribe" to actually reflect what is being done.
+  * 
   * Revision 4.3.2.5  90/05/04  00:44:07  sob
   * Fixes to add_newsgroup() from lar@usl.edu.
   * 
***************
*** 259,265
  /* returns TRUE if found or added, FALSE if not. */
  /* assumes that we are chdir'ed to SPOOL */
  
- #ifdef SERVER
  static int addnewbydefault = 0;
  #endif SERVER
  

--- 272,277 -----
  /* returns TRUE if found or added, FALSE if not. */
  /* assumes that we are chdir'ed to SPOOL */
  
  static int addnewbydefault = 0;
  
  bool
***************
*** 261,267
  
  #ifdef SERVER
  static int addnewbydefault = 0;
- #endif SERVER
  
  bool
  get_ng(what,do_reloc)

--- 273,278 -----
  /* assumes that we are chdir'ed to SPOOL */
  
  static int addnewbydefault = 0;
  
  bool
  get_ng(what,do_reloc)
***************
*** 327,333
  	        ng = add_newsgroup(ngname, ':');
  	        do_reloc = FALSE;
  	} else {
! #endif SERVER
  #ifdef VERBOSE
  	IF(verbose)
  	    sprintf(promptbuf,"\nNewsgroup %s not in .newsrc--add? [yn] ",ngname);

--- 338,344 -----
  	        ng = add_newsgroup(ngname, ':');
  	        do_reloc = FALSE;
  	} else {
! #endif /* SERVER */
  #ifdef VERBOSE
  	IF(verbose)
  	    sprintf(promptbuf,"\nNewsgroup %s not in .newsrc--subscribe? [ynY] ",ngname);
***************
*** 330,336
  #endif SERVER
  #ifdef VERBOSE
  	IF(verbose)
! 	    sprintf(promptbuf,"\nNewsgroup %s not in .newsrc--add? [yn] ",ngname);
  	ELSE
  #endif
  #ifdef TERSE

--- 341,347 -----
  #endif /* SERVER */
  #ifdef VERBOSE
  	IF(verbose)
! 	    sprintf(promptbuf,"\nNewsgroup %s not in .newsrc--subscribe? [ynY] ",ngname);
  	ELSE
  #endif
  #ifdef TERSE
***************
*** 334,340
  	ELSE
  #endif
  #ifdef TERSE
! 	    sprintf(promptbuf,"\nAdd %s? [yn] ",ngname);
  #endif
  reask_add:
  	in_char(promptbuf,'A');

--- 345,351 -----
  	ELSE
  #endif
  #ifdef TERSE
! 	    sprintf(promptbuf,"\nSubscribe %s? [ynY] ",ngname);
  #endif
  reask_add:
  	in_char(promptbuf,'A');
***************
*** 346,352
  	if (*buf == 'h') {
  #ifdef VERBOSE
  	    IF(verbose)
! 		printf("Type y or SP to add %s to your .newsrc.\n", ngname)
  		  FLUSH;
  	    ELSE
  #endif

--- 357,363 -----
  	if (*buf == 'h') {
  #ifdef VERBOSE
  	    IF(verbose)
! 		printf("Type y or SP to add %s to your .newsrc.\nType Y to add all new groups to the end of your .newsrc.\n", ngname)
  		  FLUSH;
  	    ELSE
  #endif
***************
*** 351,357
  	    ELSE
  #endif
  #ifdef TERSE
! 		fputs("y or SP to add\n",stdout) FLUSH;
  #endif
  	    fputs(ntoforget,stdout) FLUSH;
  	    goto reask_add;

--- 362,368 -----
  	    ELSE
  #endif
  #ifdef TERSE
! 		fputs("y or SP to add, Y to add all new groups\n",stdout) FLUSH;
  #endif
  	    fputs(ntoforget,stdout) FLUSH;
  	    goto reask_add;
***************
*** 364,370
  	    ng = add_newsgroup(ngname, ':');
  	    do_reloc = FALSE;
  	}
- #ifdef SERVER
  	else if (*buf == 'Y') {
  	    fputs(
  	"(I'll add all new newsgroups to the end of your .newsrc.)\n", stdout);

--- 375,380 -----
  	    ng = add_newsgroup(ngname, ':');
  	    do_reloc = FALSE;
  	}
  	else if (*buf == 'Y') {
  	    fputs(
  	"(I'll add all new newsgroups to the end of your .newsrc.)\n", stdout);
***************
*** 373,379
  	    ng = add_newsgroup(ngname, ':');
  	    do_reloc = FALSE;
  	}
- #endif SERVER
  	else {
  	    fputs(hforhelp,stdout) FLUSH;
  	    settle_down();

--- 383,388 -----
  	    ng = add_newsgroup(ngname, ':');
  	    do_reloc = FALSE;
  	}
  	else {
  	    fputs(hforhelp,stdout) FLUSH;
  	    settle_down();
***************
*** 381,387
  	}
  #ifdef SERVER
        }
! #endif SERVER
      }
      else if (rcchar[ng] == NEGCHAR) {	/* unsubscribed? */
  #ifdef VERBOSE

--- 390,396 -----
  	}
  #ifdef SERVER
        }
! #endif
      }
      else if (rcchar[ng] == NEGCHAR) {	/* unsubscribed? */
  #ifdef VERBOSE
***************
*** 917,924
      if (rcfp == Nullfp) {			/* not there? */
  #ifdef VERBOSE
  	IF(verbose)
! 	    fputs("\
! Trying to set up a .newsrc file--running newsetup...\n\n\
  ",stdout) FLUSH;
  	ELSE
  #endif

--- 926,932 -----
      if (rcfp == Nullfp) {			/* not there? */
  #ifdef VERBOSE
  	IF(verbose)
! 	    fputs("\nTrying to set up a .newsrc file--running newsetup...\n\n\
  ",stdout) FLUSH;
  	ELSE
  #endif
***************
*** 929,936
  	    (rcfp = fopen(rcname,"r")) == Nullfp) {
  #ifdef VERBOSE
  	    IF(verbose)
! 		fputs("\
! Can't create a .newsrc--you must do it yourself.\n\
  ",stdout) FLUSH;
  	    ELSE
  #endif

--- 937,943 -----
  	    (rcfp = fopen(rcname,"r")) == Nullfp) {
  #ifdef VERBOSE
  	    IF(verbose)
! 		fputs("\nCan't create a .newsrc--you must do it yourself.\n\
  ",stdout) FLUSH;
  	    ELSE
  #endif
***************
*** 973,979
  	if (debug & DEB_NEWSRC_LINE)
  	    printf("%s\n",rcline[tmpng]) FLUSH;
  #endif
! 	fprintf(rcfp,"%s\n",rcline[tmpng]);
  	if (delim)
  	    *delim = '\0';		/* might still need this line */
      }

--- 980,993 -----
  	if (debug & DEB_NEWSRC_LINE)
  	    printf("%s\n",rcline[tmpng]) FLUSH;
  #endif
! 	if (fprintf(rcfp,"%s\n",rcline[tmpng]) < 0){
! 			printf("Can't recreate .newsrc\n") FLUSH;
! 			fclose(rcfp);			/* close .newsrc */
! 			UNLINK(rctname);
! 			finalize(1);
!     		}
! 
! 			;
  	if (delim)
  	    *delim = '\0';		/* might still need this line */
      }

Index: util.c
Prereq: 4.3.2.6
*** old/util.c	Thu Nov  8 02:24:01 1990
--- new/util.c	Thu Nov  8 02:29:23 1990
***************
*** 1,4
! /* $Header: util.c,v 4.3.2.6 90/04/23 00:24:42 sob Exp $
   *
   * $Log:	util.c,v $
   * Revision 4.3.2.6  90/04/23  00:24:42  sob

--- 1,4 -----
! /* $Header: util.c,v 4.3.2.7 90/10/01 01:52:18 sob Exp $
   *
   * $Log:	util.c,v $
   * Revision 4.3.2.7  90/10/01  01:52:18  sob
***************
*** 1,6
  /* $Header: util.c,v 4.3.2.6 90/04/23 00:24:42 sob Exp $
   *
   * $Log:	util.c,v $
   * Revision 4.3.2.6  90/04/23  00:24:42  sob
   * A bit of clean up.
   * 

--- 1,10 -----
  /* $Header: util.c,v 4.3.2.7 90/10/01 01:52:18 sob Exp $
   *
   * $Log:	util.c,v $
+  * Revision 4.3.2.7  90/10/01  01:52:18  sob
+  * Altered the preprocessor defines on GETWD/GETCWD per suggestion by
+  * rsm@math.arizona.edu.
+  * 
   * Revision 4.3.2.6  90/04/23  00:24:42  sob
   * A bit of clean up.
   * 
***************
*** 50,56
  char *s, *shl;
  {
      int status, pid, w;
-     SIGRET (*signal())();
      char *shell;
  
  #ifdef SIGTSTP

--- 54,59 -----
  char *s, *shl;
  {
      int status, pid, w;
      char *shell;
  
  #ifdef SIGTSTP
***************
*** 251,256
  /*
   * Get working directory
   */
  #ifdef GETCWD
  char *
  getwd(np)

--- 254,260 -----
  /*
   * Get working directory
   */
+ #ifndef GETWD
  #ifdef GETCWD
  char *
  getwd(np)
***************
*** 262,268
      return(name);
  }
  #else
- #ifndef GETWD
  char *
  getwd(np)			/* shorter but slower */
  char *np;

--- 266,271 -----
      return(name);
  }
  #else
  char *
  getwd(np)			/* shorter but slower */
  char *np;
***************
*** 483,485
  	    *buffer = *dflt;
      }
  }

--- 486,490 -----
  	    *buffer = *dflt;
      }
  }
+ 
+ 
Index: patchlevel
Prereq: 47
*** old/patchlevel	Thu Nov  8 02:23:32 1990
--- new/patchlevel	Thu Nov  8 02:28:44 1990
***************
*** 1,2
! Patch #: 47
  

--- 1,2 -----
! Patch #: 48