| 719 | } |
| 720 | |
| 721 | void append_conflicts_hint(struct index_state *istate, |
| 722 | struct strbuf *msgbuf, enum commit_msg_cleanup_mode cleanup_mode) |
| 723 | { |
| 724 | int i; |
| 725 | |
| 726 | if (cleanup_mode == COMMIT_MSG_CLEANUP_SCISSORS) { |
| 727 | strbuf_addch(msgbuf, '\n'); |
| 728 | wt_status_append_cut_line(msgbuf); |
| 729 | strbuf_addstr(msgbuf, comment_line_str); |
| 730 | } |
| 731 | |
| 732 | strbuf_addch(msgbuf, '\n'); |
| 733 | strbuf_commented_addf(msgbuf, comment_line_str, "Conflicts:\n"); |
| 734 | for (i = 0; i < istate->cache_nr;) { |
| 735 | const struct cache_entry *ce = istate->cache[i++]; |
| 736 | if (ce_stage(ce)) { |
| 737 | strbuf_commented_addf(msgbuf, comment_line_str, |
| 738 | "\t%s\n", ce->name); |
| 739 | while (i < istate->cache_nr && |
| 740 | !strcmp(ce->name, istate->cache[i]->name)) |
| 741 | i++; |
| 742 | } |
| 743 | } |
| 744 | } |
| 745 | |
| 746 | static int do_recursive_merge(struct repository *r, |
| 747 | struct commit *base, struct commit *next, |
no test coverage detected