git-clone: stop dumb protocol from copying refs outside heads/ and tags/.

Most notably, the original code first copied refs/remotes/ that
remote side had to local, and overwrote them by mapping refs/heads/
from the remote when a dumb protocol transport was used.

This makes the clone behaviour by dumb protocol in line with the
git native and rsync transports.

Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Junio C Hamano 2006-11-24 19:07:24 -08:00
Родитель 7002243f7e
Коммит 983d2ee284
1 изменённых файлов: 4 добавлений и 0 удалений

Просмотреть файл

@ -48,6 +48,10 @@ Perhaps git-update-server-info needs to be run there?"
case "$name" in
*^*) continue;;
esac
case "$bare,$name" in
yes,* | ,heads/* | ,tags/*) ;;
*) continue ;;
esac
if test -n "$use_separate_remote" &&
branch_name=`expr "z$name" : 'zheads/\(.*\)'`
then