From 0eea5a6e91d3da6932c13f16fdf4b4e5ed91b93c Mon Sep 17 00:00:00 2001 From: Sun He Date: Sun, 2 Mar 2014 15:30:11 +0800 Subject: write_pack_file: use correct variable in diagnostic 'pack_tmp_name' is the subject of the utime() check, so report it in the warning, not the uninitialized 'tmpname' Signed-off-by: Sun He Reviewed-by: Eric Sunshine Signed-off-by: Junio C Hamano diff --git a/builtin/pack-objects.c b/builtin/pack-objects.c index dd117b3..f3a44c4 100644 --- a/builtin/pack-objects.c +++ b/builtin/pack-objects.c @@ -783,7 +783,7 @@ static void write_pack_file(void) utb.modtime = --last_mtime; if (utime(pack_tmp_name, &utb) < 0) warning("failed utime() on %s: %s", - tmpname, strerror(errno)); + pack_tmp_name, strerror(errno)); } /* Enough space for "-.pack"? */ -- cgit v0.10.2-6-g49f6