Disable SIGPIPE. This can happen under a variety of circumstances,
authorChris Hanson <org/chris-hanson/cph>
Thu, 15 Nov 1990 08:43:06 +0000 (08:43 +0000)
committerChris Hanson <org/chris-hanson/cph>
Thu, 15 Nov 1990 08:43:06 +0000 (08:43 +0000)
and we almost never want Scheme to terminate (a possible exception
being when it happens on stdout).  According to HP-UX documentation,
disabling this signal causes the system calls that would have
generated it to return EPIPE instead, which requires no special work
for us to handle.

v7/src/microcode/uxsig.c

index 5e717d59dd6c85285d969e77b3a1f7259ab39bc7..42b31d54f1e453265e0884b4f1cf62231ce20566 100644 (file)
@@ -1,6 +1,6 @@
 /* -*-C-*-
 
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/uxsig.c,v 1.4 1990/11/13 08:45:09 cph Exp $
+$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/uxsig.c,v 1.5 1990/11/15 08:43:06 cph Exp $
 
 Copyright (c) 1990 Massachusetts Institute of Technology
 
@@ -621,6 +621,10 @@ DEFUN_VOID (UX_initialize_signals)
   bind_handler (SIGUSR2,       sighnd_renice);
 #endif
   bind_handler (SIGCHLD,       sighnd_dead_subprocess);
+  /* If this signal is ignored, then the system call that would have
+     caused it will return EPIPE instead.  This is much easier for us
+     to handle. */
+  bind_handler (SIGPIPE,       SIG_IGN);
   if ((isatty (STDIN_FILENO)) || option_emacs_subprocess)
     {
       if (!option_emacs_subprocess)