DragonFly commits List (threaded) for 2011-08
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
git: sh: Set $? to 0 for background commands.
commit 5d4731c8351e78f0e4bf4cc5b6997b92110c3fbd
Author: Peter Avalos <pavalos@dragonflybsd.org>
Date: Sat Jul 2 13:59:09 2011 -1000
sh: Set $? to 0 for background commands.
For backgrounded pipelines and subshells, the previous value of $? was
being preserved, which is incorrect.
For backgrounded simple commands containing a command substitution, the
status of the last command substitution was returned instead of 0.
If fork() fails, this is an error.
Obtained-from: FreeBSD SVN rev 221027
Summary of changes:
bin/sh/eval.c | 11 +++++++----
tools/regression/bin/sh/execution/bg1.0 | 3 +++
tools/regression/bin/sh/execution/bg2.0 | 5 +++++
tools/regression/bin/sh/execution/bg3.0 | 5 +++++
4 files changed, 20 insertions(+), 4 deletions(-)
create mode 100644 tools/regression/bin/sh/execution/bg1.0
create mode 100644 tools/regression/bin/sh/execution/bg2.0
create mode 100644 tools/regression/bin/sh/execution/bg3.0
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/5d4731c8351e78f0e4bf4cc5b6997b92110c3fbd
--
DragonFly BSD source repository
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]