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-08-31 02:06:02 +0300
committerJunio C Hamano <gitster@pobox.com>2021-08-31 02:06:03 +0300
commit669277c551604fddcb4dc9dac888cd956cccacd3 (patch)
tree796823188e1c01d907f37bfa4c309d1ae60ca804 /builtin
parentb81a85ecd82239386fc22f5f3c6914155e029ce8 (diff)
parent00e302da76591f2bda43d9bf58bf366729ee485c (diff)
Merge branch 'cb/builtin-merge-format-string-fix'
Code clean-up. * cb/builtin-merge-format-string-fix: builtin/merge: avoid -Wformat-extra-args from ancient Xcode
Diffstat (limited to 'builtin')
-rw-r--r--builtin/merge.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/builtin/merge.c b/builtin/merge.c
index ec8ff88a33..febb0c99c9 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);