From: Junio C Hamano Date: Tue, 9 Jul 2019 22:25:34 +0000 (-0700) Subject: Merge branch 'fc/fetch-with-import-fix' X-Git-Tag: v2.23.0-rc0~93 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=dbf491e9e947141eab7ffce65d6c97c121def6e0;p=git Merge branch 'fc/fetch-with-import-fix' Code restructuring during 2.20 period broke fetching tags via "import" based transports. * fc/fetch-with-import-fix: fetch: fix regression with transport helpers fetch: make the code more understandable fetch: trivial cleanup t5801 (remote-helpers): add test to fetch tags t5801 (remote-helpers): cleanup refspec stuff --- dbf491e9e947141eab7ffce65d6c97c121def6e0 diff --cc builtin/fetch.c index 4ba63d5ac6,e485d429c9..f2be50a4a3 --- a/builtin/fetch.c +++ b/builtin/fetch.c @@@ -317,9 -321,10 +323,9 @@@ static void find_non_local_tags(const s !has_object_file_with_flags(&ref->old_oid, OBJECT_INFO_QUICK) && !will_fetch(head, ref->old_oid.hash) && - !has_sha1_file_with_flags(item->oid.hash, - OBJECT_INFO_QUICK) && + !has_object_file_with_flags(&item->oid, OBJECT_INFO_QUICK) && !will_fetch(head, item->oid.hash)) - oidclr(&item->oid); + clear_item(item); item = NULL; continue; } @@@ -331,9 -336,9 +337,9 @@@ * fetch. */ if (item && - !has_sha1_file_with_flags(item->oid.hash, OBJECT_INFO_QUICK) && + !has_object_file_with_flags(&item->oid, OBJECT_INFO_QUICK) && !will_fetch(head, item->oid.hash)) - oidclr(&item->oid); + clear_item(item); item = NULL; @@@ -352,9 -357,9 +358,9 @@@ * checked to see if it needs fetching. */ if (item && - !has_sha1_file_with_flags(item->oid.hash, OBJECT_INFO_QUICK) && + !has_object_file_with_flags(&item->oid, OBJECT_INFO_QUICK) && !will_fetch(head, item->oid.hash)) - oidclr(&item->oid); + clear_item(item); /* * For all the tags in the remote_refs_list,