Junio C Hamano <gits...@pobox.com> writes:

> Michael Haggerty <mhag...@alum.mit.edu> writes:
> ...
>> * The second branch of the if is *never* executed.
>               else if (args.fetch_all &&
>                        (!args.depth || prefixcmp(ref->name, "refs/tags/") )) {
>                       *newtail = ref;
>                       ref->next = NULL;
>                       newtail = &ref->next;
>                       continue;
>               }
> I am not familiar with (nor particularly interested in) the "args.depth"
> code, so I have no comment on this part offhand.

This is "fetch --all" case.  I think the original intent was to
fetch all branches (hence exclusion of tags) so the prefixcmp() may
not be correct (!prefixcmp() with "refs/heads" would be more kosher)
these days.  I am not sure what !args.depth check wants to do here
(that is, I can see it wants to defeat "fetch --all" and instead
make it go through the usual refspec matching codepath, but I do not
know why we thought that is a good thing to do here).

To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to