On Mon, Jan 09, 2012 at 10:37:45AM -0600, Jonathan Nieder wrote:
> Michael Welsh Duggan wrote:
> > I am trying to determine why:

> >   dash -c "sleep 5 & kill %1"

> > results in:

> >   dash: 1: kill: No such process

> You are probably looking for the -m option.

The cause is that the -m option ("job control") enables running commands
in separate process groups, and dash follows literally what POSIX says
about kill %job: a background process group should be signaled; however,
there is no background process group. Some shells signal one or more
processes they know are part of the job in this case, but dash calls
kill() on a process group that is guaranteed not to exist.

-- 
Jilles Tjoelker
--
To unsubscribe from this list: send the line "unsubscribe dash" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to