kill '-SIGHUP', pgid -vs- kill 'SIGHUP', 0 
Author Message
 kill '-SIGHUP', pgid -vs- kill 'SIGHUP', 0

AFAIK

  Process.kill '-SIGHUP', Process.getpgrp

should be equivalent to

  Process.kill 'SIGHUP', 0

but i'm not sure if this would always (say in solaris) be the case.  is one
preferred or more portable?

-a

--

 ====================================
 | Ara Howard
 | NOAA Forecast Systems Laboratory
 | Information and Technology Services
 | Data Systems Group
 | R/FST 325 Broadway
 | Boulder, CO 80305-3328

 | Phone:  303-497-7238
 | Fax:    303-497-7259
 ====================================



Sun, 24 Jul 2005 13:43:55 GMT  
 kill '-SIGHUP', pgid -vs- kill 'SIGHUP', 0

Quote:

> AFAIK

>   Process.kill '-SIGHUP', Process.getpgrp

> should be equivalent to

>   Process.kill 'SIGHUP', 0

> but i'm not sure if this would always (say in solaris) be the case.  is one
> preferred or more portable?

$ uname -a

$ man 2 kill
...
     If pid is greater than zero:
             Sig is sent to the process whose ID is equal to pid.
     If pid is zero:
             Sig is sent to all processes whose group ID is equal to the pro-
             cess group ID of the sender, and for which the process has per-
             mission; this is a variant of killpg(2).
     If pid is -1:
             If the user has super-user privileges, the signal is sent to all
             processes excluding system processes (with P_SYSTEM flag set),
             process with ID 1 (usually init(8)), and the process sending the
             signal.  If the user is not the super user, the signal is sent to
             all processes with the same uid as the user excluding the process
             sending the signal.  No error is returned if any process could be
             signaled.
...
STANDARDS
     The kill() function call is expected to conform to ISO/IEC 9945-1:1990
     (``POSIX.1'').

--

All messages signed with fingerprint:
FEC2 57F1 D465 EB15 5D6E  7C11 332A 551C 796C 9F04

  application_pgp-signature_part
< 1K Download


Sun, 24 Jul 2005 14:31:31 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Killing processes without using 'kill'

2. Thread#kill doesn't kill processes inside a thread

3. Please help- Killing Python 'processes'

4. Killing a thread from a 'controller'

5. PLEASE DON'T KILL THE LIST

6. Vispro Rexx can't kill a rxftp thread

7. fixpak#10 kills visual rexx'es

8. What killed my programme's performance?

9. I (don' ) will kill my Python

10. f90 and f77's precision difference kills me

11. DB: Gadfly 's killing my DB files

12. vwait doesn't kill background processes on NT (only)

 

 
Powered by phpBB® Forum Software