[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Thu, 21 May 2009 11:55:55 +0200
I have found a discrepancy between documentation (man page) and
behavior of Bash under -e switch. In documentation it is written:
The shell does not exit if the command that fails is part of the
command list immediately following a while or until keyword, part of
the test in an if statement, part of a && or || list, or if the
command's return value is being inverted via !.
And it is true, this does not exit:
false && false
but strange is that this does:
false || false
Why is that? Is this a bug? A documentation discrepancy?
I am running GNU bash, version 3.2.17(1)-release (i386-apple-darwin9.0).
- Documentation discrepancy,