Skip to content

Commit 9836ca9

Browse files
committed
branch: git branch upstream functions layouts have been fixed.
1 parent ea889b3 commit 9836ca9

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/branch.c

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -471,25 +471,27 @@ int git_branch_upstream_name(
471471
typedef enum {
472472
GIT_BRANCH_UPSTREAM_FORMAT_REMOTE = 1,
473473
GIT_BRANCH_UPSTREAM_FORMAT_MERGE = 2
474-
} git_branch_upstream_format;
474+
} git_branch_upstream_format_type_t;
475475

476-
static const char* git_branch_upstream_format_string_for_id(git_branch_upstream_format id) {
476+
static const char* git_branch_upstream_format_string_for_id(git_branch_upstream_format_type_t id)
477+
{
477478
switch (id) {
478479
case GIT_BRANCH_UPSTREAM_FORMAT_REMOTE: return "branch.%s.remote";
479480
case GIT_BRANCH_UPSTREAM_FORMAT_MERGE: return "branch.%s.merge";
480481
default: return ""; // OK?
481482
};
482483
}
483484

484-
static const char* git_branch_upstream_format_name_for_id(git_branch_upstream_format id) {
485+
static const char* git_branch_upstream_format_name_for_id(git_branch_upstream_format_type_t id)
486+
{
485487
switch (id) {
486488
case GIT_BRANCH_UPSTREAM_FORMAT_REMOTE: return "remote";
487489
case GIT_BRANCH_UPSTREAM_FORMAT_MERGE: return "merge";
488490
default: return "UNDEFINED"; // OK?
489491
};
490492
}
491493

492-
static int git_branch_upstream_with_format(git_buf *buf, git_repository *repo, const char *refname, git_branch_upstream_format id)
494+
static int git_branch_upstream_with_format(git_buf *buf, git_repository *repo, const char *refname, git_branch_upstream_format_type_t id)
493495
{
494496
int error;
495497
git_config *cfg;

0 commit comments

Comments
 (0)