This is the mail archive of the
cygwin-developers@cygwin.com
mailing list for the Cygwin project.
second try: [PATCH] finishing spawn / vfork signal inheritance
- From: Joe Buehler <jbuehler at hekimian dot com>
- To: cygwin-developers at cygwin dot com
- Date: Mon, 24 Mar 2003 14:21:00 -0500
- Subject: second try: [PATCH] finishing spawn / vfork signal inheritance
- Organization: Spirent Communications, Inc.
- References: <3E79FA1B.60302@hekimian.com>
- Reply-to: jbuehler at hekimian dot com
If someone with CVS access would commit this, I would appreciate it.
Currently, spawn() and vfork() do not pass signal handler settings
on to the child process, and this breaks ksh93. This patch fixes
the problem (in conjunction with a change cgf already committed).
2003-03-20 Joe Buehler <jhpb at draco dot hekimian dot com>
* spawn.cc: (spawn_guts): copy signal handler info to spawned child.
Index: spawn.cc
===================================================================
RCS file: /cvs/src/src/winsup/cygwin/spawn.cc,v
retrieving revision 1.120
diff -u -r1.120 spawn.cc
--- spawn.cc 13 Feb 2003 02:52:41 -0000 1.120
+++ spawn.cc 20 Mar 2003 17:26:55 -0000
@@ -756,6 +756,8 @@
}
child->dwProcessId = pi.dwProcessId;
child->hProcess = pi.hProcess;
+ /* make child inherit our signal settings */
+ child->copysigs (myself);
child.remember ();
strcpy (child->progname, real_path);
/* FIXME: This introduces an unreferenced, open handle into the child.
--
Joe Buehler