i want to know that one particuler process is running or not?
is there any standard unix system call exist by which i can know about the present status of a process whose PID is known to us?
plz help.
i want to know that one particuler process is running or not?
is there any standard unix system call exist by which i can know about the present status of a process whose PID is known to us?
plz help.
Which flavour of Unix?
As far as I know, there is no STANDARD way in Unix/Linux to get information about another process. Obviously process status (ps) will know how to do that, and there IS a way, but there's no definitely standardized way to do this.
Linux and several other Unix flavours have pseudo-files under /proc/<pid>/... that give all sorts of information.
The SIMPLE (and standard) way to deal with it, however, is to use the signal SIG_CHILD which gets sent to the owning process when the child process dies.
--
Mats
Compilers can produce warnings - make the compiler programmers happy: Use them!
Please don't PM me for help - and no, I don't do help over instant messengers.