Merge branch 'nd/diff-flush-before-warning' into maint

Avoid showing a warning message in the middle of a line of "git
diff" output.

* nd/diff-flush-before-warning:
  diff.c: flush stdout before printing rename warnings
This commit is contained in:
Junio C Hamano 2018-03-22 14:24:09 -07:00
commit b32221935e

1
diff.c
View File

@ -5454,6 +5454,7 @@ N_("you may want to set your %s variable to at least "
void diff_warn_rename_limit(const char *varname, int needed, int degraded_cc)
{
fflush(stdout);
if (degraded_cc)
warning(_(degrade_cc_to_c_warning));
else if (needed)