summaryrefslogtreecommitdiff
path: root/src/clone.c
diff options
context:
space:
mode:
authornulltoken <emeric.fermas@gmail.com>2012-10-07 21:00:46 +0200
committernulltoken <emeric.fermas@gmail.com>2012-10-07 21:03:37 +0200
commit096d9e94aa9e19669e778c8644ccfa7f41f98eaf (patch)
tree349f22d6e6754d295a2c7c5c42b77c784e93d2e3 /src/clone.c
parent74a24005146d0f908b2660db5f7e198adad4ab64 (diff)
downloadlibgit2-096d9e94aa9e19669e778c8644ccfa7f41f98eaf.tar.gz
remote: use constants for well-known names
Diffstat (limited to 'src/clone.c')
-rw-r--r--src/clone.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/clone.c b/src/clone.c
index 9dfc22c59..211288c2c 100644
--- a/src/clone.c
+++ b/src/clone.c
@@ -51,7 +51,7 @@ static int create_tracking_branch(git_repository *repo, const git_oid *target, c
if (!git_buf_printf(&remote, "branch.%s.remote", name) &&
!git_buf_printf(&merge, "branch.%s.merge", name) &&
!git_buf_printf(&merge_target, GIT_REFS_HEADS_DIR "%s", name) &&
- !git_config_set_string(cfg, git_buf_cstr(&remote), "origin") &&
+ !git_config_set_string(cfg, git_buf_cstr(&remote), GIT_REMOTE_ORIGIN) &&
!git_config_set_string(cfg, git_buf_cstr(&merge), git_buf_cstr(&merge_target))) {
retcode = 0;
}
@@ -150,7 +150,7 @@ static int setup_remotes_and_fetch(git_repository *repo,
if (!fetch_stats) fetch_stats = &dummy_stats;
/* Create the "origin" remote */
- if (!git_remote_add(&origin, repo, "origin", origin_url)) {
+ if (!git_remote_add(&origin, repo, GIT_REMOTE_ORIGIN, origin_url)) {
/* Connect and download everything */
if (!git_remote_connect(origin, GIT_DIR_FETCH)) {
if (!git_remote_download(origin, &bytes, fetch_stats)) {