From: Pete Wyckoff Date: Mon, 30 Apr 2012 00:28:46 +0000 (-0400) Subject: remove blank filename in error message X-Git-Tag: v1.7.11-rc0~66^2 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=5eaeda70de1e7763d070e8ccfbcd8ca10baea800;p=git.git remove blank filename in error message When write_loose_object() finds that it is unable to create a temporary file, it complains, for instance: unable to create temporary sha1 filename : Too many open files That extra space was supposed to be the name of the file, and will be an empty string if the git_mkstemps_mode() fails. The name of the temporary file is unimportant; delete it. Signed-off-by: Pete Wyckoff Signed-off-by: Junio C Hamano --- diff --git a/sha1_file.c b/sha1_file.c index c8d572d13..3c4f1652f 100644 --- a/sha1_file.c +++ b/sha1_file.c @@ -2511,7 +2511,7 @@ static int write_loose_object(const unsigned char *sha1, char *hdr, int hdrlen, if (errno == EACCES) return error("insufficient permission for adding an object to repository database %s", get_object_directory()); else - return error("unable to create temporary sha1 filename %s: %s", tmp_file, strerror(errno)); + return error("unable to create temporary file: %s", strerror(errno)); } /* Set it up */