summaryrefslogtreecommitdiff
path: root/git-quiltimport.sh
diff options
context:
space:
mode:
authorGerrit Pape <pape@smarden.org>2009-02-24 09:00:06 +0000
committerJunio C Hamano <gitster@pobox.com>2009-02-25 00:49:13 -0800
commit6ab149ea89fe5790630c5750af0e3245a7a5e06e (patch)
tree1beb8ff2b9ba00f11c813bb96b5f23009c05d4ae /git-quiltimport.sh
parent6a0861a8a3295395238c8126c6e74c66b715c595 (diff)
downloadgit-6ab149ea89fe5790630c5750af0e3245a7a5e06e.tar.gz
git-quiltimport: preserve standard input to be able to read user input
When run without --author and it fails to determine an author, git quiltimport tries `read patch_author` to get user input, but standard input has been redirected to the patch series file. This commit lets quiltimport read the series file through file descriptor 3 so that the standard input is preserved. Reported by Uwe Kleine-König through http://bugs.debian.org/515910 Signed-off-by: Gerrit Pape <pape@smarden.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-quiltimport.sh')
-rwxr-xr-xgit-quiltimport.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/git-quiltimport.sh b/git-quiltimport.sh
index cebaee1cc9..9a6ba2b987 100755
--- a/git-quiltimport.sh
+++ b/git-quiltimport.sh
@@ -63,7 +63,7 @@ tmp_info="$tmp_dir/info"
commit=$(git rev-parse HEAD)
mkdir $tmp_dir || exit 2
-while read patch_name level garbage
+while read patch_name level garbage <&3
do
case "$patch_name" in ''|'#'*) continue;; esac
case "$level" in
@@ -134,5 +134,5 @@ do
commit=$( (echo "$SUBJECT"; echo; cat "$tmp_msg") | git commit-tree $tree -p $commit) &&
git update-ref -m "quiltimport: $patch_name" HEAD $commit || exit 4
fi
-done <"$QUILT_PATCHES/series"
+done 3<"$QUILT_PATCHES/series"
rm -rf $tmp_dir || exit 5