Skip to content

Commit

Permalink
remote-curl: use http_fetch_ref() instead of walker wrapper
Browse files Browse the repository at this point in the history
The http-walker implementation of walker->fetch_ref() doesn't do
anything special compared to http_fetch_ref() anyway.

Remove init_walker() invocation before fetching the ref, since we aren't
using the walker wrapper and don't need a walker instance anymore.

Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Tay Ray Chuan authored and Junio C Hamano committed Mar 2, 2010
1 parent 888692b commit aec4975
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions remote-curl.c
Original file line number Diff line number Diff line change
Expand Up @@ -249,9 +249,8 @@ static struct ref *parse_info_refs(struct discovery *heads)
i++;
}

init_walker();
ref = alloc_ref("HEAD");
if (!walker->fetch_ref(walker, ref) &&
if (!http_fetch_ref(url, ref) &&
!resolve_remote_symref(ref, refs)) {
ref->next = refs;
refs = ref;
Expand Down

0 comments on commit aec4975

Please sign in to comment.