diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/branch.c | 6 | ||||
-rw-r--r-- | src/remote.c | 8 | ||||
-rw-r--r-- | src/submodule.c | 4 |
3 files changed, 9 insertions, 9 deletions
diff --git a/src/branch.c b/src/branch.c index 52760853b..9a3cb07ed 100644 --- a/src/branch.c +++ b/src/branch.c @@ -360,7 +360,7 @@ int git_branch_upstream_name( } if (strcmp(".", remote_name) != 0) { - if ((error = git_remote_load(&remote, repo, remote_name)) < 0) + if ((error = git_remote_lookup(&remote, repo, remote_name)) < 0) goto cleanup; refspec = git_remote__matching_refspec(remote, merge_name); @@ -411,7 +411,7 @@ int git_branch_remote_name(git_buf *buf, git_repository *repo, const char *refna /* Find matching remotes */ for (i = 0; i < remote_list.count; i++) { - if ((error = git_remote_load(&remote, repo, remote_list.strings[i])) < 0) + if ((error = git_remote_lookup(&remote, repo, remote_list.strings[i])) < 0) continue; fetchspec = git_remote__matching_dst_refspec(remote, refname); @@ -556,7 +556,7 @@ int git_branch_set_upstream(git_reference *branch, const char *upstream_name) goto on_error; } else { /* Get the remoe-tracking branch's refname in its repo */ - if (git_remote_load(&remote, repo, git_buf_cstr(&value)) < 0) + if (git_remote_lookup(&remote, repo, git_buf_cstr(&value)) < 0) goto on_error; fetchspec = git_remote__matching_dst_refspec(remote, git_reference_name(upstream)); diff --git a/src/remote.c b/src/remote.c index 0007c41db..4b9993dbd 100644 --- a/src/remote.c +++ b/src/remote.c @@ -186,7 +186,7 @@ static int ensure_remote_doesnot_exist(git_repository *repo, const char *name) int error; git_remote *remote; - error = git_remote_load(&remote, repo, name); + error = git_remote_lookup(&remote, repo, name); if (error == GIT_ENOTFOUND) return 0; @@ -350,7 +350,7 @@ static int get_optional_config( return error; } -int git_remote_load(git_remote **out, git_repository *repo, const char *name) +int git_remote_lookup(git_remote **out, git_repository *repo, const char *name) { git_remote *remote; git_buf buf = GIT_BUF_INIT; @@ -1677,7 +1677,7 @@ int git_remote_rename(git_strarray *out, git_repository *repo, const char *name, assert(out && repo && name && new_name); - if ((error = git_remote_load(&remote, repo, name)) < 0) + if ((error = git_remote_lookup(&remote, repo, name)) < 0) return error; if ((error = ensure_remote_name_is_valid(new_name)) < 0) @@ -2010,7 +2010,7 @@ static int remove_remote_tracking(git_repository *repo, const char *remote_name) size_t i, count; /* we want to use what's on the config, regardless of changes to the instance in memory */ - if ((error = git_remote_load(&remote, repo, remote_name)) < 0) + if ((error = git_remote_lookup(&remote, repo, remote_name)) < 0) return error; count = git_remote_refspec_count(remote); diff --git a/src/submodule.c b/src/submodule.c index ccc8ad117..8dca0ae73 100644 --- a/src/submodule.c +++ b/src/submodule.c @@ -1876,7 +1876,7 @@ static int lookup_head_remote(git_remote **remote, git_repository *repo) /* lookup remote of remote tracking branch name */ if (!(error = lookup_head_remote_key(&remote_name, repo))) - error = git_remote_load(remote, repo, remote_name.ptr); + error = git_remote_lookup(remote, repo, remote_name.ptr); git_buf_free(&remote_name); @@ -1890,7 +1890,7 @@ static int lookup_default_remote(git_remote **remote, git_repository *repo) /* if that failed, use 'origin' instead */ if (error == GIT_ENOTFOUND) - error = git_remote_load(remote, repo, "origin"); + error = git_remote_lookup(remote, repo, "origin"); if (error == GIT_ENOTFOUND) giterr_set( |