Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
builtin/worktree.c: use error_errno()
author
Nguyễn Thái Ngọc Duy
<pclouds@gmail.com>
Sun, 8 May 2016 09:47:34 +0000
(16:47 +0700)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 9 May 2016 19:29:08 +0000
(12:29 -0700)
While at there, improve the error message to say _what_ failed to
remove.
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/worktree.c
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(from parent 1:
17bef17
)
diff --git
a/builtin/worktree.c
b/builtin/worktree.c
index 38b56096bd3b914d1128e0bebb5c964a3cdd1b74..df4f6606c1061de2501f35aceebba558e2bab0f2 100644
(file)
--- a/
builtin/worktree.c
+++ b/
builtin/worktree.c
@@
-109,7
+109,7
@@
static void prune_worktrees(void)
if (ret < 0 && errno == ENOTDIR)
ret = unlink(path.buf);
if (ret)
- error
(_("failed to remove: %s"), strerror(errno)
);
+ error
_errno(_("failed to remove '%s'"), path.buf
);
}
closedir(dir);
if (!show_only)