diff-tree: don't write headers if the diff queue is empty
This is not a pickaxe-specific thing, we do this regardless of what has pruned down the diff queue.maint
parent
881b07654c
commit
9ab55bd29a
|
@ -267,13 +267,13 @@ static int call_diff_flush(void)
|
||||||
if (detect_rename)
|
if (detect_rename)
|
||||||
diffcore_rename(detect_rename, diff_score_opt);
|
diffcore_rename(detect_rename, diff_score_opt);
|
||||||
diffcore_prune();
|
diffcore_prune();
|
||||||
if (pickaxe) {
|
if (pickaxe)
|
||||||
diffcore_pickaxe(pickaxe);
|
diffcore_pickaxe(pickaxe);
|
||||||
|
|
||||||
if (diff_queue_is_empty()) {
|
if (diff_queue_is_empty()) {
|
||||||
diff_flush(DIFF_FORMAT_NO_OUTPUT, 0);
|
diff_flush(DIFF_FORMAT_NO_OUTPUT, 0);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (nr_paths)
|
if (nr_paths)
|
||||||
diffcore_pathspec(paths);
|
diffcore_pathspec(paths);
|
||||||
if (header) {
|
if (header) {
|
||||||
|
|
Loading…
Reference in New Issue