mirror of
https://github.com/Kitware/CMake.git
synced 2026-04-24 23:28:32 -05:00
KWSys: Use "ps -Af" for process list on QNX
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
This commit is contained in:
@@ -2380,6 +2380,9 @@ static pid_t kwsysProcessFork(kwsysProcess* cp,
|
||||
#elif defined(__hpux) || defined(__sparc) || defined(__sgi) || defined(_AIX)
|
||||
# define KWSYSPE_PS_COMMAND "ps -ef"
|
||||
# define KWSYSPE_PS_FORMAT "%*s %d %d %*[^\n]\n"
|
||||
#elif defined(__QNX__)
|
||||
# define KWSYSPE_PS_COMMAND "ps -Af"
|
||||
# define KWSYSPE_PS_FORMAT "%*d %d %d %*[^\n]\n"
|
||||
#elif defined(__CYGWIN__)
|
||||
# define KWSYSPE_PS_COMMAND "ps aux"
|
||||
# define KWSYSPE_PS_FORMAT "%d %d %*[^\n]\n"
|
||||
|
||||
Reference in New Issue
Block a user