aboutsummaryrefslogtreecommitdiffstats
path: root/src/process.c
diff options
context:
space:
mode:
authorRichard M. Stallman1998-08-15 05:53:00 +0000
committerRichard M. Stallman1998-08-15 05:53:00 +0000
commit5651af6d63e449c3e463dcb4c00766c2cf230c30 (patch)
treeffa1b487e76fb17bd674008ed858f3eced2889d6 /src/process.c
parent09ba2aa0b62f8e4693a99d33404e147493c231f9 (diff)
downloademacs-5651af6d63e449c3e463dcb4c00766c2cf230c30.tar.gz
emacs-5651af6d63e449c3e463dcb4c00766c2cf230c30.zip
(wait_reading_process_input): If a pty gives EIO,
raise SIGCHLD just in case.
Diffstat (limited to 'src/process.c')
-rw-r--r--src/process.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/process.c b/src/process.c
index 2ca75250706..0e5ae9e3fe2 100644
--- a/src/process.c
+++ b/src/process.c
@@ -2676,9 +2676,13 @@ wait_reading_process_input (time_limit, microsecs, read_kbd, do_display)
2676 Therefore, if we get an error reading and errno = 2676 Therefore, if we get an error reading and errno =
2677 EIO, just continue, because the child process has 2677 EIO, just continue, because the child process has
2678 exited and should clean itself up soon (e.g. when we 2678 exited and should clean itself up soon (e.g. when we
2679 get a SIGCHLD). */ 2679 get a SIGCHLD).
2680
2681 However, it has been known to happen that the SIGCHLD
2682 got lost. So raise the signl again just in case.
2683 It can't hurt. */
2680 else if (nread == -1 && errno == EIO) 2684 else if (nread == -1 && errno == EIO)
2681 ; 2685 kill (getpid (), SIGCHLD);
2682#endif /* HAVE_PTYS */ 2686#endif /* HAVE_PTYS */
2683 /* If we can detect process termination, don't consider the process 2687 /* If we can detect process termination, don't consider the process
2684 gone just because its pipe is closed. */ 2688 gone just because its pipe is closed. */