summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Jon Seymour <jon.seymour@gmail.com>2011-08-04 22:00:58 +1000
committerLibravatar Junio C Hamano <gitster@pobox.com>2011-08-04 15:33:34 -0700
commit6ba7acffdd24e9ed9b31e503ce87f2af31cd0883 (patch)
treea11c1e81edc6caf54102f20fa6fd84a4ba49935e
parentbisect: move argument parsing before state modification. (diff)
downloadtgif-6ba7acffdd24e9ed9b31e503ce87f2af31cd0883.tar.xz
bisect: use && to connect statements that are deferred with eval.
Christian Couder pointed out that the existing eval strategy swallows an initial non-zero return. Using && to connect the statements should fix this. Signed-off-by: Jon Seymour <jon.seymour@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rwxr-xr-xgit-bisect.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/git-bisect.sh b/git-bisect.sh
index 20f6dd5625..a44ffe1ead 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -86,7 +86,7 @@ bisect_start() {
0) state='bad' ; bad_seen=1 ;;
*) state='good' ;;
esac
- eval="$eval bisect_write '$state' '$rev' 'nolog'; "
+ eval="$eval bisect_write '$state' '$rev' 'nolog' &&"
shift
;;
esac
@@ -145,7 +145,7 @@ bisect_start() {
#
echo "$start_head" >"$GIT_DIR/BISECT_START" &&
git rev-parse --sq-quote "$@" >"$GIT_DIR/BISECT_NAMES" &&
- eval "$eval" &&
+ eval "$eval true" &&
echo "git bisect start$orig_args" >>"$GIT_DIR/BISECT_LOG" || exit
#
# Check if we can proceed to the next bisect state.