[comp.mail.elm] elm 2.1PL1 - commands fail with external pager

cudcv@warwick.ac.uk (Rob McMahon) (12/20/88)

When using an external pager, commands other than return do not work from the
`Press return to return to elm' prompt.  The forked child carefully exits with
the key pressed as its exit status, but the parent throws the information
away.  It's even commented ... we care!  This patch is for Berkeley systems
only I'm afraid.  Other systems should use `return((status >> 8) & 0xff);'
this would work on Berkeley too if status was always declared as `int', rather
than as `union wait'.

-- 
RCS file: /usr/local/src/elm/src/showmsg.c,v
retrieving revision 2.1
retrieving revision 2.1.1.1
diff -c -r2.1 -r2.1.1.1
*** /tmp/,RCSt1a02728	Tue Dec 20 12:00:42 1988
--- /tmp/,RCSt2a02728	Tue Dec 20 12:00:44 1988
***************
*** 548,554 ****
  	signal(SIGINT, istat);
  	signal(SIGQUIT, qstat);
  
! 	/** used to return status, but who cares?  Just get BACK! **/
  
! 	return(0);
  }
--- 551,557 ----
  	signal(SIGINT, istat);
  	signal(SIGQUIT, qstat);
  
! 	/** return exit status to say what command to run next **/
  
! 	return(status.w_retcode);
  }
-- 
Rob
-- 
UUCP:   ...!mcvax!ukc!warwick!cudcv	PHONE:  +44 203 523037
JANET:  cudcv@uk.ac.warwick             ARPA:   cudcv@warwick.ac.uk
Rob McMahon, Computing Services, Warwick University, Coventry CV4 7AL, England