diff options
author | Dmitry Lobanov <gaussblurinc@gmail.com> | 2021-05-16 18:02:23 +0300 |
---|---|---|
committer | Dmitry Lobanov <gaussblurinc@gmail.com> | 2021-05-16 18:02:23 +0300 |
commit | 9836ca9177a56b6e170997b2e727c71ff8228848 (patch) | |
tree | f91d48074280e53a45fa7888e160efb6f7734a4d | |
parent | ea889b3e1237fc4399f0907f923c8df4fff3a72b (diff) | |
download | libgit2-9836ca9177a56b6e170997b2e727c71ff8228848.tar.gz |
branch: git branch upstream functions layouts have been fixed.
-rw-r--r-- | src/branch.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/branch.c b/src/branch.c index 007b93591..831ccfcc7 100644 --- a/src/branch.c +++ b/src/branch.c @@ -471,9 +471,10 @@ cleanup: typedef enum { GIT_BRANCH_UPSTREAM_FORMAT_REMOTE = 1, GIT_BRANCH_UPSTREAM_FORMAT_MERGE = 2 -} git_branch_upstream_format; +} git_branch_upstream_format_type_t; -static const char* git_branch_upstream_format_string_for_id(git_branch_upstream_format id) { +static const char* git_branch_upstream_format_string_for_id(git_branch_upstream_format_type_t id) +{ switch (id) { case GIT_BRANCH_UPSTREAM_FORMAT_REMOTE: return "branch.%s.remote"; case GIT_BRANCH_UPSTREAM_FORMAT_MERGE: return "branch.%s.merge"; @@ -481,7 +482,8 @@ static const char* git_branch_upstream_format_string_for_id(git_branch_upstream_ }; } -static const char* git_branch_upstream_format_name_for_id(git_branch_upstream_format id) { +static const char* git_branch_upstream_format_name_for_id(git_branch_upstream_format_type_t id) +{ switch (id) { case GIT_BRANCH_UPSTREAM_FORMAT_REMOTE: return "remote"; case GIT_BRANCH_UPSTREAM_FORMAT_MERGE: return "merge"; @@ -489,7 +491,7 @@ static const char* git_branch_upstream_format_name_for_id(git_branch_upstream_fo }; } -static int git_branch_upstream_with_format(git_buf *buf, git_repository *repo, const char *refname, git_branch_upstream_format id) +static int git_branch_upstream_with_format(git_buf *buf, git_repository *repo, const char *refname, git_branch_upstream_format_type_t id) { int error; git_config *cfg; |