File: C:/Ruby27-x64/share/ri/2.7.0/system/Process/kill-c.ri
U:RDoc::AnyMethod[iI" kill:ETI"Process::kill;TT:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"QSends the given signal to the specified process id(s) if _pid_ is positive. ;TI"QIf _pid_ is zero, _signal_ is sent to all processes whose group ID is equal ;TI"Qto the group ID of the process. If _pid_ is negative, results are dependent ;TI"Jon the operating system. _signal_ may be an integer signal number or ;TI"Qa POSIX signal name (either with or without a +SIG+ prefix). If _signal_ is ;TI"Mnegative (or starts with a minus sign), kills process groups instead of ;TI"@processes. Not all signals are available on all platforms. ;TI"LThe keys and values of Signal.list are known signal names and numbers, ;TI"respectively.;To:RDoc::Markup::BlankLine o:RDoc::Markup::Verbatim; [I"pid = fork do
;TI"2 Signal.trap("HUP") { puts "Ouch!"; exit }
;TI" # ... do some work ...
;TI" end
;TI"# ...
;TI"Process.kill("HUP", pid)
;TI"Process.wait
;T:@format0o;
; [I"<em>produces:</em>;T@o;; [I"Ouch!
;T;
0o;
; [ I"FIf _signal_ is an integer but wrong for signal, Errno::EINVAL or ;TI"GRangeError will be raised. Otherwise unless _signal_ is a String ;TI"Aor a Symbol, and a known signal name, ArgumentError will be ;TI"raised.;T@o;
; [I"FAlso, Errno::ESRCH or RangeError for invalid _pid_, Errno::EPERM ;TI"Dwhen failed because of no privilege, will be raised. In these ;TI">cases, signals may have been sent to preceding processes.;T:
@fileI"process.c;T:0@omit_headings_from_table_of_contents_below0I"2Process.kill(signal, pid, ...) -> integer
;T0[ I"(*args);T@1FI"Process;TcRDoc::NormalModule00