@matheusbsbs / matheus-bagliano / commits / cdb3950801
Fork 0

Forward port the "funny ref avoidance" in clone and fetch from maint branch.

Somehow I forgot to forward port these fixes. "git clone" from a repository prepared with the latest update-server-info would fail without this patch. Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Oct 17, 2005 at 21:47 UTC cdb3950801fec8e9efa1607093a6e51737bacba0
2 files changed +6 -2
git-clone.sh
+5 -1
@@ -53,7 +53,11 @@ Perhaps git-update-server-info needs to be run there?"
53 while read sha1 refname
54 do
55 name=`expr "$refname" : 'refs/\(.*\)'` &&
56 - git-http-fetch -v -a -w "$name" "$name" "$1/" || exit 1
56 + case "$name" in
57 + *^*) ;;
58 + *)
59 + git-http-fetch -v -a -w "$name" "$name" "$1/" || exit 1
60 + esac
61 done <"$clone_tmp/refs"
62 rm -fr "$clone_tmp"
63 }
git-fetch.sh
+1 -1
@@ -176,7 +176,7 @@ if test "$tags"
176 then
177 taglist=$(git-ls-remote --tags "$remote" |
178 sed -e '
179 - /\^{}$/d
179 + /\^/d
180 s/^[^ ]* //
181 s/.*/&:&/')
182 if test "$#" -gt 1