diff options
author | Johannes Schindelin <Johannes.Schindelin@gmx.de> | 2008-03-02 15:53:04 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2008-03-02 15:27:08 -0800 |
commit | 5d02294c776c46f0d454470c66c16fe9f08fad3d (patch) | |
tree | f30963dac3a72151ea97a3293157a2eb2cdf433f /builtin-log.c | |
parent | 6dfbb304be5a5e260321c5f47626582dbe2c62f0 (diff) | |
download | git-5d02294c776c46f0d454470c66c16fe9f08fad3d.tar.gz |
format-patch: use the diff options for the cover letter, too
Earlier, when you called "git format-patch --cover-letter -M", the
diffstat in the cover letter would not inherit the "-M". Now it does.
While at it, add a few "|| break" statements in the test's loops;
otherwise, breakages inside the loops would not be caught.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-log.c')
-rw-r--r-- | builtin-log.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin-log.c b/builtin-log.c index bbadbc0de2..fd9b3ae95e 100644 --- a/builtin-log.c +++ b/builtin-log.c @@ -694,8 +694,8 @@ static void make_cover_letter(struct rev_info *rev, int use_stdout, if (!origin) return; - diff_setup(&opts); - opts.output_format |= DIFF_FORMAT_SUMMARY | DIFF_FORMAT_DIFFSTAT; + memcpy(&opts, &rev->diffopt, sizeof(opts)); + opts.output_format = DIFF_FORMAT_SUMMARY | DIFF_FORMAT_DIFFSTAT; diff_setup_done(&opts); |