[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Alternate termination sequence option --term-seq
From: |
Ole Tange |
Subject: |
Re: Alternate termination sequence option --term-seq |
Date: |
Sat, 2 May 2015 01:50:28 +0200 |
On Thu, Apr 30, 2015 at 12:47 PM, Rasmus Villemoes
<rv@rasmusvillemoes.dk> wrote:
;
> One can call setpgid on behalf of another process. So GNU Parallel can
> put the child created by open3 in its own process group by doing
> setpgid(child, 0) (equivalently setpgid(child, child)). In Perl, it
> seems that the wrapper for the setpgid system call is setpgrp, but the
> semantics should be the same.
But that does not seem to work. This kills burnP6:
perl -MIPC::Open3 -e 'if($f=open3(A,B,C,"burnP6")) { 1;} sleep 2;kill
"TERM",$f'
This does not:
perl -MIPC::Open3 -e 'if($f=open3(A,B,C,"burnP6")) { setpgrp($f,$f);}
sleep 2;kill "TERM",-$f'
/Ole
- Re: Alternate termination sequence option --term-seq,
Ole Tange <=