mirror of
https://github.com/git/git.git
synced 2024-12-03 06:53:53 +08:00
Merge branch 'cw/fetch-remote-group-with-duplication'
"git fetch <group>", when "<group>" of remotes lists the same remote twice, unnecessarily failed when parallel fetching was enabled, which has been corrected. * cw/fetch-remote-group-with-duplication: fetch: fix duplicate remote parallel fetch bug
This commit is contained in:
commit
d26e26a3f5
@ -2228,6 +2228,7 @@ int cmd_fetch(int argc, const char **argv, const char *prefix)
|
||||
argv++;
|
||||
}
|
||||
}
|
||||
string_list_remove_duplicates(&list, 0);
|
||||
|
||||
if (negotiate_only) {
|
||||
struct oidset acked_commits = OIDSET_INIT;
|
||||
|
@ -99,4 +99,13 @@ test_expect_success 'updating remote name updates that remote' '
|
||||
! repo_fetched two
|
||||
'
|
||||
|
||||
test_expect_success 'updating group in parallel with a duplicate remote does not fail (fetch)' '
|
||||
mark fetch-group-duplicate &&
|
||||
update_repo one &&
|
||||
git config --add remotes.duplicate one &&
|
||||
git config --add remotes.duplicate one &&
|
||||
git -c fetch.parallel=2 remote update duplicate &&
|
||||
repo_fetched one
|
||||
'
|
||||
|
||||
test_done
|
||||
|
Loading…
Reference in New Issue
Block a user