diff.c: flush stdout before printing rename warnings
[gitweb.git] / diff.c
diff --git a/diff.c b/diff.c
index fe6f59160fd70a6dc801d3a67c61484dda521fb1..bfd1bd2410f9d0b920fda58cb0caae33a94111e7 100644 (file)
--- a/diff.c
+++ b/diff.c
@@ -1954,7 +1954,7 @@ static void show_dirstat(struct diff_options *options)
                if (DIFF_FILE_VALID(p->one) && DIFF_FILE_VALID(p->two)) {
                        diff_populate_filespec(p->one, 0);
                        diff_populate_filespec(p->two, 0);
-                       diffcore_count_changes(p->one, p->two, NULL, NULL, 0,
+                       diffcore_count_changes(p->one, p->two, NULL, NULL,
                                               &copied, &added);
                        diff_free_filespec_data(p->one);
                        diff_free_filespec_data(p->two);
@@ -4623,6 +4623,7 @@ static const char rename_limit_advice[] =
 
 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)