- May 19, 2014
-
-
Brad King authored
When we kill a child we send SIGSTOP first so that we can traverse its child processes recursively. On unwinding the recursion we then send SIGKILL. Current Cygwin has trouble when both signals are sent in quick succession by the parent process. Add a usleep(1) after sending the first signal to give up our time slice and give Cygwin a chance to process the first signal before sending the second. Change-Id: I75ab55cf969a0ea6104a9798c761c0ba1fcd1dbc
-
- Dec 03, 2013
-
-
Rolf Eike Beer authored
If a group of processes needs to be terminated recursively the entry in /proc doesn't need to be kept open during the recursion as all the interesting information was already read from it. Especially in case of deeper recursion this lowers the memory pressure. Change-Id: I95b969f42c8dd68b57cdaf8fc1b705f358f1dc58
-
- Mar 21, 2013
-
-
The Single UNIX (R) Specification, Version 2 defines "FD_SETSIZE", but does not specify the effects if it's (re)defined by an application. Cygwin's newlib headers document that FD_SETSIZE may be defined by the user [1] and should be >= NOFILE. [2] Setting it to 16384 uses a value from Cygwin's poll() implementation. [3] [1]: http://cygwin.com/cgi-bin/cvsweb.cgi/src/newlib/libc/include/sys/types.h?cvsroot=src [2]: http://cygwin.com/cgi-bin/cvsweb.cgi/src/winsup/cygwin/include/sys/param.h?cvsroot=src [3]: http://cygwin.com/cgi-bin/cvsweb.cgi/src/winsup/cygwin/poll.cc?cvsroot=src Change-Id: Idc43fc28a398979da1e9289e1080a9fc1090c605
-
- Jan 25, 2013
-
-
Change-Id: I4e44d61c175e1deb4cecdebfdba5fa05cbdd1e6b
-
- Jan 11, 2013
-
-
Brad King authored
Change-Id: I55506c112cfffdb8d56a85bae0eeaae91d4035bf
-
- Jan 06, 2013
-
-
Rolf Eike Beer authored
Change-Id: I881521d84a31b6b1c68930f94acbcea88b5c1dea
-
- Oct 06, 2012
-
-
Change-Id: Ic1dcd37dabbf34ce721b81c6a787dafe758105a4
-
- Jun 11, 2010
- May 11, 2010
-
-
Brad King authored
kFreeBSD and Hurd have the same userland as Linux. This change is necessary to enable kwsysProcessKill() to kill child processes on kFreeBSD. The bug was detected by CTestTestTimeout test. Patch from "Modestas Vainius <modestas@vainius.eu>". See issue #10432.
-
- Apr 19, 2010
-
-
Brad King authored
Patch from Chuck Atkins <chuck.atkins@kitware.com>
-
- Mar 18, 2010
-
-
Brad King authored
Teach kwsysProcessKill to identify processes on this platform using the "ps" command just as on Linux. Patch from Modestas Vainius <modax@debian.org>. See issue #10432.
-
- Jan 12, 2010
-
-
Brad King authored
Open output files with mode 0666 so that permissions are not more strict than umask permits. See issue #10126.
-
- Dec 01, 2009
-
-
Brad King authored
In order to kill process trees we need to list all processes to find those whose parent we are killing. We implement process listing on OpenSolaris by using "ps -ef" and parsing the resulting format: UID PID PPID C STIME TTY TIME CMD %*s %d %d %*[^\n]\n
-
Brad King authored
In order to kill process trees we need to list all processes to find those whose parent we are killing. We implement process listing on QNX using "ps -Af" and parsing the resulting format: UID PID PPID C STIME TTY TIME CMD %*d %d %d %*[^\n]\n
-
- Nov 30, 2009
-
-
Brad King authored
On UNIX systems we kill a tree of processes by performing a DFS walk of the tree. We send SIGSTOP to each process encountered, recursively handle its children, and then send SIGKILL. We once used the above approach in the past, but it was removed by the commit "Do not send both SIGSTOP and SIGKILL when killing a process". The commit was meant to work-around an OS X 10.3 bug in which the child would not always honor SIGKILL after SIGSTOP. At the time we wrongly assumed that the process tree remains intact after SIGKILL and before the child is reaped. In fact the grandchildren may be re-parented to ppid=1 even before the child is reaped, which causes the DFS walk to miss them.
-
- Oct 19, 2009
-
-
Alexander Neundorf authored
Alex
-
- Sep 28, 2009
-
-
Brad King authored
This converts the KWSys license to a pure 3-clause OSI-approved BSD License. We drop the previous license clause requiring modified versions to be plainly marked. We also update the KWSys copyright to cover the full development time range.
-
- Jul 13, 2009
-
-
Brad King authored
Add System_Parse_CommandForUnix to the KWSys System interface as a utility to parse a unix-style command line. Move the existing implementation out of ProcessUNIX. Add a flags argument reserved for future use in providing additional behavior.
-
- Jun 12, 2009
-
-
Brad King authored
This helps avoid fixing VMS-specific code for non-VMS compilers where it isn't needed anyway.
-
Francois Bertel authored
COMP:Fixed warning with gcc 4.3.3: passing argument 1 of kwsysProcessSetVMSFeature discards qualifiers from pointer target type.
-
- Jun 10, 2009
-
-
Brad King authored
This achieves basic process execution on OpenVMS. We use work-arounds for different fork()/exec() behavior and a lack of select(). VMS emulates fork/exec using setjmp/longjmp to evaluate the child and parent return cases from fork. Therefore both must be invoked from the same function. Since select() works only for sockets we use the BeOS-style polling implementation. However, non-blocking reads on empty pipes cannot be distinguished easily from the last read on a closed pipe. Therefore we identify end of data by an empty read after the child terminates.
-
Brad King authored
This avoids use of an uninitialized value in the KWSys ProcessUNIX polling implementation when no timeout is given.
-
- Apr 23, 2009
-
-
Bill Hoffman authored
ENH: check in almost building VMS stuff with VMSBuild directory since the bootstrap script will not work on VMS
-
- Mar 16, 2009
-
-
Francois Bertel authored
-
Francois Bertel authored
COMP:Fixed gcc 4.3.2 warning with -O1 and above: ignoring return value of read'), declared with attribute warn_unused_result
-
Francois Bertel authored
-
- Dec 15, 2008
-
-
Francois Bertel authored
-
- Sep 22, 2008
-
-
Bill Hoffman authored
-
- Sep 15, 2008
-
-
Bill Hoffman authored
-
- Aug 20, 2008
-
-
Brad King authored
According to "man select" on Linux it is possible that select() lies about data being ready on a pipe in some subtle cases. We deal with this by switching to non-blocking i/o and checking for EAGAIN. See issue #7180.
-
- May 13, 2008
-
-
Mathieu Malaterre authored
ENH: all ctype function have the same issue: char can be signed or unsigned, since isspace only deal with >=0 value (except EOF) one has to first cast it to unsigned char
-
- May 12, 2008
-
-
Bill Lorensen authored
-
- Apr 02, 2008
-
-
Mathieu Malaterre authored
-
- Jan 10, 2008
-
-
Brad King authored
BUG: Fix hang in Process_Kill on OS X caused by an OS bug in which a pipe read end cannot be closed if the pipe write end is open, the pipe is full, and another process is blocking waiting to write. Work around the problem by killing the children before closing the pipes.
-
- Jun 27, 2007
-
-
Brad King authored
-
- May 16, 2007
-
-
Brad King authored
BUG: Do not send both SIGSTOP and SIGKILL when killing a process. The SIGSTOP seems to be able to block the SIGKILL occasionally. Also the SIGKILL is sufficient since the process table entry will still exist until it is reaped with waitpid.
-
- May 03, 2007
-
-
Brad King authored
-
- Dec 05, 2006
-
-
Bill Hoffman authored
-
Bill Hoffman authored
-