Code

difftool: Update copyright notices to list each year separately
[git.git] / merge-recursive.c
index cd3628c4d9b1831c73e752b3b49c9d88b9e23098..dd4fbd0e6bc22f2e5f5667205b47165f8aebbbd0 100644 (file)
@@ -87,6 +87,7 @@ static void flush_output(struct merge_options *o)
        }
 }
 
+__attribute__((format (printf, 3, 4)))
 static void output(struct merge_options *o, int v, const char *fmt, ...)
 {
        int len;
@@ -203,7 +204,8 @@ struct tree *write_tree_from_memory(struct merge_options *o)
                for (i = 0; i < active_nr; i++) {
                        struct cache_entry *ce = active_cache[i];
                        if (ce_stage(ce))
-                               output(o, 0, "%d %.*s", ce_stage(ce), ce_namelen(ce), ce->name);
+                               output(o, 0, "%d %.*s", ce_stage(ce),
+                                      (int)ce_namelen(ce), ce->name);
                }
                return NULL;
        }