Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2021-10-12 23:51:23 +0300
committerJunio C Hamano <gitster@pobox.com>2021-10-12 23:51:23 +0300
commit6a0699bccc03e83b90ace5d170686d3c28e7237f (patch)
tree24d473c4c17486b5725fd320c116da887fc9a5f4
parent367e9feee21af039d03103f0781757f0e9724168 (diff)
parent00e302da76591f2bda43d9bf58bf366729ee485c (diff)
Merge branch 'cb/builtin-merge-format-string-fix' into maint
Code clean-up. * cb/builtin-merge-format-string-fix: builtin/merge: avoid -Wformat-extra-args from ancient Xcode
-rw-r--r--builtin/merge.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/builtin/merge.c b/builtin/merge.c
index a3282bf0e8..097a74b139 100644
--- a/builtin/merge.c
+++ b/builtin/merge.c
@@ -862,9 +862,11 @@ static void prepare_to_commit(struct commit_list *remoteheads)
strbuf_commented_addf(&msg, "\n");
}
strbuf_commented_addf(&msg, _(merge_editor_comment));
- strbuf_commented_addf(&msg, _(cleanup_mode == COMMIT_MSG_CLEANUP_SCISSORS ?
- scissors_editor_comment :
- no_scissors_editor_comment), comment_line_char);
+ if (cleanup_mode == COMMIT_MSG_CLEANUP_SCISSORS)
+ strbuf_commented_addf(&msg, _(scissors_editor_comment));
+ else
+ strbuf_commented_addf(&msg,
+ _(no_scissors_editor_comment), comment_line_char);
}
if (signoff)
append_signoff(&msg, ignore_non_trailer(msg.buf, msg.len), 0);