summaryrefslogtreecommitdiff
path: root/git-mergetool--lib.sh
diff options
context:
space:
mode:
authorJay Soffian <jaysoffian@gmail.com>2011-09-19 19:40:52 -0400
committerJunio C Hamano <gitster@pobox.com>2011-09-19 17:41:49 -0700
commite622f41dcd97861796c7529712170f9eae07dc56 (patch)
tree03aa1a788b47d2b24e0ef06ee8d9375328ec23e7 /git-mergetool--lib.sh
parent740a8fc2249cf7d8b39ab50a25bbf86554158ae7 (diff)
downloadgit-e622f41dcd97861796c7529712170f9eae07dc56.tar.gz
git-mergetool: check return value from read
Mostly fixed already by 6b44577 (mergetool: check return value from read, 2011-07-01). Catch two uses it missed. Signed-off-by: Jay Soffian <jaysoffian@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-mergetool--lib.sh')
-rw-r--r--git-mergetool--lib.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/git-mergetool--lib.sh b/git-mergetool--lib.sh
index 4db9212331..a79a2ecd49 100644
--- a/git-mergetool--lib.sh
+++ b/git-mergetool--lib.sh
@@ -38,7 +38,7 @@ check_unchanged () {
while true; do
echo "$MERGED seems unchanged."
printf "Was the merge successful? [y/n] "
- read answer
+ read answer || return 1
case "$answer" in
y*|Y*) status=0; break ;;
n*|N*) status=1; break ;;