From e4ddc8f72b5a7d8c55a6c2042c7b7f945ba4b1a2 Mon Sep 17 00:00:00 2001 From: Mark Lodato Date: Sat, 4 Sep 2010 11:30:18 -0400 Subject: fix errors in printf-style format strings There were many places where the arguments to a printf-like function did not match the format string. Mostly, these were a missing 'l' flag, but there were three exceptions: - In ui-stats.c, a size_t argument must be printed. C99 has the "%zu" flag for this purpose, but not all compilers support this. Therefore, we mimic what git does - use a NO_C99_FORMAT Makefile variable. - In ui-stats.c, cgit_print_error() was called with a pointer instead of a character. - In ui-log.c, the "columns" argument was never used. Signed-off-by: Mark Lodato --- ui-diff.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ui-diff.c') diff --git a/ui-diff.c b/ui-diff.c index 0dcabe9..7ff7e46 100644 --- a/ui-diff.c +++ b/ui-diff.c @@ -92,7 +92,7 @@ static void print_fileinfo(struct fileinfo *info) info->old_path); html(""); if (info->binary) { - htmlf("bin%d -> %d bytes", + htmlf("bin%ld -> %ld bytes", info->old_size, info->new_size); return; } -- cgit v1.2.1