Aunc.995 NET.eunice utzoo!duke!unc!whm Thu Jul 16 00:21:44 1981 Stopping from the Shells A recent conversation with Kashtan yielded a very simple solution to current inability to interrupt programs started from a shell under Eunice. In the shell, if you start a program, say cat, and tried to stop it with a ^Y, it would kill the shell, not the program. Two ^C's would do the same thing. The solution, although not very elegant is to wire in a SIGINT trap to each and every program. This can be done by inserting a call to signal in the crt0.mar module, then replacing it in libc.olb. Add the following lines to crt0.mar just before the line: calls #3,G^Main pushl #Exit ; Address of Exit routine pushl #2 ; Hardwired define value for SIGINT calls #2,G^Signal ; signal(SIGINT,exit) Reassemble crt0.mar and replace it in libc. You might want to make a backup of libc before you replace it, just in case. Now, any program that is linked, has the ^C trap builtin, if invoked from the Cshell, a ^C will stop the running program (provided it has been relinked) and return control to the Cshell. p.s. I mailed a list of changes to make 4bsd Vi work under Eunice to all those who had requested it, anybody that asked for it and didn't get it should let me know. Bill Mitchell, NCSU ----------------------------------------------------------------- gopher://quux.org/ conversion by John Goerzen of http://communication.ucsd.edu/A-News/ This Usenet Oldnews Archive article may be copied and distributed freely, provided: 1. There is no money collected for the text(s) of the articles. 2. The following notice remains appended to each copy: The Usenet Oldnews Archive: Compilation Copyright (C) 1981, 1996 Bruce Jones, Henry Spencer, David Wiseman.