summaryrefslogtreecommitdiff
path: root/editor.c
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2016-05-08 09:47:43 (GMT)
committerJunio C Hamano <gitster@pobox.com>2016-05-09 19:29:08 (GMT)
commit9f9a522c159d5f7f399c91a22e2f73287a393a57 (patch)
treed3b905509d3247f3e02340466af312ddfbd20f72 /editor.c
parenta1f06be3ff78f088aa5e71cd518b74cdf5a4d34e (diff)
downloadgit-9f9a522c159d5f7f399c91a22e2f73287a393a57.zip
git-9f9a522c159d5f7f399c91a22e2f73287a393a57.tar.gz
git-9f9a522c159d5f7f399c91a22e2f73287a393a57.tar.bz2
editor.c: use error_errno()
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'editor.c')
-rw-r--r--editor.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/editor.c b/editor.c
index 01c644c..7519ede 100644
--- a/editor.c
+++ b/editor.c
@@ -63,7 +63,6 @@ int launch_editor(const char *path, struct strbuf *buffer, const char *const *en
if (!buffer)
return 0;
if (strbuf_read_file(buffer, path, 0) < 0)
- return error("could not read file '%s': %s",
- path, strerror(errno));
+ return error_errno("could not read file '%s'", path);
return 0;
}