[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Finding if a process is runing.
- To: Oded Arbel <odeda-linux-il(at-nospam)betalfa.org.il>
- Subject: Re: Finding if a process is runing.
- From: Oleg Goldshmidt <ogoldshmidt(at-nospam)computer.org>
- Date: 08 Feb 2001 11:20:15 +0200
- Cc: Linux-IL Mailing list <linux-il(at-nospam)cs.huji.ac.il>
- In-Reply-To: Oded Arbel's message of "Thu, 8 Feb 2001 03:56:23 +0000 (/etc/localtime)"
- Organization: Speaking for myself only.
- Original-Sender: ogoldshmidt@computer.org
- References: <Pine.LNX.4.30.0102080348560.18996-100000@europa.betalfa.org.il>
- Reply-To: ogoldshmidt(at-nospam)computer.org
- Sender: ogoldshmidt(at-nospam)comgates.co.il
- Sender: linux-il-bounce(at-nospam)cs.huji.ac.il
- User-Agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Channel Islands)
Oded Arbel <odeda-linux-il@betalfa.org.il> writes:
> I'vre read somewhere (I think in one of perl's man pages) that you can use
> kill to send a "0 signal" to a process, to see if it is still
> runing.
POSIX says so, AFAIK.
> kill(2) man page seems to confirm that, saying that if sig is 0, no signal
> will be sent, but error checking is till performed
Same statement.
> I tried to use that method to check if a sub process I forked is
> still runing, and instead of returning 0 correctly (I checked with
> ps, the sub process is indeed running), it returns with the error
> code "Invalid argument". how come ?
Difficult to say. I just checked - it works for me (I can send you the
code if you like). What is this "invalid argument"? What is the errno
value? EINVAL?
--
Oleg Goldshmidt | ogoldshmidt@NOSPAM.computer.org
"... We work by wit, and not by witchcraft;
And wit depends on dilatory time." [Shakespeare]
=================================================================
To unsubscribe, send mail to linux-il-request@linux.org.il with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail linux-il-request@linux.org.il