summaryrefslogtreecommitdiff
path: root/branch.c
diff options
context:
space:
mode:
Diffstat (limited to 'branch.c')
-rw-r--r--branch.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/branch.c b/branch.c
index 28b81a7e02..1db0601a11 100644
--- a/branch.c
+++ b/branch.c
@@ -337,15 +337,20 @@ void create_branch(struct repository *r,
free(real_ref);
}
-void remove_branch_state(struct repository *r)
+void remove_merge_branch_state(struct repository *r)
{
- unlink(git_path_cherry_pick_head(r));
- unlink(git_path_revert_head(r));
unlink(git_path_merge_head(r));
unlink(git_path_merge_rr(r));
unlink(git_path_merge_msg(r));
unlink(git_path_merge_mode(r));
+}
+
+void remove_branch_state(struct repository *r)
+{
+ unlink(git_path_cherry_pick_head(r));
+ unlink(git_path_revert_head(r));
unlink(git_path_squash_msg(r));
+ remove_merge_branch_state(r);
}
void die_if_checked_out(const char *branch, int ignore_current_worktree)