Skip to content

Commit

Permalink
diff-tree: don't write headers if the diff queue is empty
Browse files Browse the repository at this point in the history
This is not a pickaxe-specific thing, we do this regardless of
what has pruned down the diff queue.
  • Loading branch information
Linus Torvalds committed May 23, 2005
1 parent 881b076 commit 9ab55bd
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions diff-tree.c
Original file line number Diff line number Diff line change
Expand Up @@ -267,12 +267,12 @@ static int call_diff_flush(void)
if (detect_rename)
diffcore_rename(detect_rename, diff_score_opt);
diffcore_prune();
if (pickaxe) {
if (pickaxe)
diffcore_pickaxe(pickaxe);
if (diff_queue_is_empty()) {
diff_flush(DIFF_FORMAT_NO_OUTPUT, 0);
return 0;
}

if (diff_queue_is_empty()) {
diff_flush(DIFF_FORMAT_NO_OUTPUT, 0);
return 0;
}
if (nr_paths)
diffcore_pathspec(paths);
Expand Down

0 comments on commit 9ab55bd

Please sign in to comment.