diff options
author | Junio C Hamano <gitster@pobox.com> | 2011-11-04 17:35:42 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-11-07 15:34:30 -0800 |
commit | cbda121c993bf14d3743c7fdf0f8c476c9f7c636 (patch) | |
tree | d9b680be1d56696b9bab53fb665ff04ae73dea00 /builtin/merge.c | |
parent | 4c0ea82da3cd35eff50377cab78208c8ef57933b (diff) | |
download | git-cbda121c993bf14d3743c7fdf0f8c476c9f7c636.tar.gz |
fmt-merge-msg: package options into a structure
This way new features can be added more easily
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/merge.c')
-rw-r--r-- | builtin/merge.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/builtin/merge.c b/builtin/merge.c index 6a44b6d485..48e7f003d3 100644 --- a/builtin/merge.c +++ b/builtin/merge.c @@ -1229,8 +1229,12 @@ int cmd_merge(int argc, const char **argv, const char *prefix) merge_name(argv[i], &merge_names); if (!have_message || shortlog_len) { - fmt_merge_msg(&merge_names, &merge_msg, !have_message, - shortlog_len); + struct fmt_merge_msg_opts opts; + memset(&opts, 0, sizeof(opts)); + opts.add_title = !have_message; + opts.shortlog_len = shortlog_len; + + fmt_merge_msg(&merge_names, &merge_msg, &opts); if (merge_msg.len) strbuf_setlen(&merge_msg, merge_msg.len - 1); } |