This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: OK to commit? - mishandled SIGCHLD ICE



> Please insert a comment explaining why this is necessary, so someone
> doesn't take it out again.

2001-03-08  Bruce Korb  <bkorb@gnu.org>

	gcc.c(main): ensure SIGCHLD handling is set to SIG_DFL so that
	wait4() can receive the signal.

Index: gcc.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/gcc.c,v
retrieving revision 1.212
diff -u -r1.212 gcc.c
--- gcc.c       2001/03/04 09:08:17     1.212
+++ gcc.c       2001/03/08 23:21:06
@@ -5517,6 +5517,9 @@
   if (signal (SIGPIPE, SIG_IGN) != SIG_IGN)
     signal (SIGPIPE, fatal_error);
 #endif
+  /* We *MUST* set SIGCHLD to SIG_DFL so that the wait4() call will
+     receive the signal.  A different setting is inheritable */
+  signal (SIGCHLD, SIG_DFL);
 
   argbuf_length = 10;
   argbuf = (const char **) xmalloc (argbuf_length * sizeof (const char *));


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]