tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: sh -e changes broke pkgsrc



On Mon, May 26, 2008 at 11:41:56PM +0300, Aleksey Cheusov wrote:
 > > According to POSIX only failing *simple commands* are supposed to
 > > cause -e exits. So this is not true...
 > 
 > Strictly speaking you right.  Though, this is nonsense IMHO.
 > 
 > [examples]

Those are moot in connection with the specific point about non-simple
commands, because they contain failing simple commands within them.

You need something like "set -e; false || (set +e; false)" which
shouldn't exit even if "set -e; false || false" does exit because of
the right-hand false.

-- 
David A. Holland
dholland%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index