From: Junio C Hamano Date: Mon, 29 Jul 2019 19:38:23 +0000 (-0700) Subject: Merge branch 'fc/fetch-with-import-fix' into maint X-Git-Tag: v2.23.0-rc0~1^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7011ce12b895d172562dcaa7d8b240f3594dc981;p=thirdparty%2Fgit.git Merge branch 'fc/fetch-with-import-fix' into maint 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 --- 7011ce12b895d172562dcaa7d8b240f3594dc981 diff --cc builtin/fetch.c index fc6c879bcf,e485d429c9..c9b92b1e52 --- 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,