Newsreaders...

Stuart Levy slevy at s1.msi.umn.edu
Sun May 19 05:50:36 AEST 1991


In article <1991May16.161042.11782 at news.iastate.edu> bryan at pi.eai.iastate.edu (Bryan Manske) writes:
>In Article #9295 damc at dap.csiro.au (Don McCormick) writes:
>
>>Reading of news articles using rn is not a problem, but if you try to
>>reply to an article or save an article on some occasions you can drop
>>out of rn with the error.
>
>>        "Unexpected close of server socket"
>
>>Does anyone have a solution to this problem?

Besides the ``#define vfork fork'' fix already mentioned, SGI [r]rn users
might want to apply this patch to rn/term.c:

*** /tmp/,RCSt1a09955	Sat May 18 14:12:50 1991
--- term.c	Wed Apr 10 21:29:31 1991
***************
*** 607,613 ****
  	return 1;
      }
      else {
! 	size = read(0,addr,size);
  #ifdef RAWONLY
  	*addr &= 0177;
  #endif
--- 608,618 ----
  	return 1;
      }
      else {
! 	int got = read(0,addr,size);
! 	if(got < 0) {
! 		while((got = read(0,addr,size)) < 0 && errno == EINTR)
! 		    ;
! 	}
  #ifdef RAWONLY
  	*addr &= 0177;
  #endif

It ignores spurious terminal read errors, which the SGI tty driver
seems to return even on unsatisfied single-byte reads when returning
from caught signals.  If [r]rn dies when you resume after ^Z, try this.

Also it's worth changing the set of libraries from  "-lcurses -lbsd"
to "-lcurses -lsun -lbsd -lc_s".  -lsun (if you have it) supplies yellow
pages, so ~username works on YP systems.  -lc_s just shrinks the binary a bit.

	Stuart Levy, Geometry Center, University of Minnesota
	slevy at geom.umn.edu



More information about the Comp.sys.sgi mailing list