pull.sh: quote $upload_pack when passing it to git-fetch
The previous code broke for example git pull --upload-pack 'echo --foo' Reported-by: Joey Hess <id@joeyh.name> Fix-suggested-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Matthieu Moy committed
Jul 30, 2015 at 22:40 UTC
22d6857d46de7ca28445c40782ba87a66416790d
1 file changed
+1
-1
git-pull.sh
+1
-1
@@ -295,7 +295,7 @@ test true = "$rebase" && {
295
}
296
orig_head=$(git rev-parse -q --verify HEAD)
297
git fetch $verbosity $progress $dry_run $recurse_submodules $all $append \
298
-$upload_pack $force $tags $prune $keep $depth $unshallow $update_shallow \
298
+${upload_pack+"$upload_pack"} $force $tags $prune $keep $depth $unshallow $update_shallow \
299
$refmap --update-head-ok "$@" || exit 1
300
test -z "$dry_run" || exit 0
301