Skip to content

Commit

Permalink
DIFF_FORMAT_RAW is not default anymore
Browse files Browse the repository at this point in the history
diff_setup() used to initialize output_format to DIFF_FORMAT_RAW.  Now
the default is 0 (no output) so don't compare against DIFF_FORMAT_RAW to
see if any diff format command line flags were given.

Signed-off-by: Timo Hirvonen <tihirvon@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
  • Loading branch information
Timo Hirvonen authored and Junio C Hamano committed Jun 26, 2006
1 parent c9b5ef9 commit 0e677e1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
5 changes: 1 addition & 4 deletions builtin-log.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,8 @@ static int cmd_log_wc(int argc, const char **argv, char **envp,
rev->verbose_header = 1;
argc = setup_revisions(argc, argv, rev, "HEAD");
if (rev->always_show_header) {
if (rev->diffopt.pickaxe || rev->diffopt.filter) {
if (rev->diffopt.pickaxe || rev->diffopt.filter)
rev->always_show_header = 0;
if (rev->diffopt.output_format == DIFF_FORMAT_RAW)
rev->diffopt.output_format = DIFF_FORMAT_NO_OUTPUT;
}
}

if (argc > 1)
Expand Down
3 changes: 1 addition & 2 deletions revision.c
Original file line number Diff line number Diff line change
Expand Up @@ -851,8 +851,7 @@ int setup_revisions(int argc, const char **argv, struct rev_info *revs, const ch
}
if (revs->combine_merges) {
revs->ignore_merges = 0;
if (revs->dense_combined_merges &&
(revs->diffopt.output_format != DIFF_FORMAT_DIFFSTAT))
if (revs->dense_combined_merges && !revs->diffopt.output_format)
revs->diffopt.output_format = DIFF_FORMAT_PATCH;
}
revs->diffopt.abbrev = revs->abbrev;
Expand Down

0 comments on commit 0e677e1

Please sign in to comment.