summaryrefslogtreecommitdiff
path: root/command/chown.c
diff options
context:
space:
mode:
Diffstat (limited to 'command/chown.c')
-rw-r--r--command/chown.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/command/chown.c b/command/chown.c
index 164e3b4..dcb6941 100644
--- a/command/chown.c
+++ b/command/chown.c
@@ -6,7 +6,6 @@
#include <stdlib.h>
#include <sys/stat.h>
#include <unistd.h>
-#include <errno.h>
#include <string.h>
#include <sys/types.h>
#include <pwd.h>
@@ -60,7 +59,7 @@ static void chown_file(char* path) {
if (chown(get_path_buffer(), flags.uid, flags.gid) < 0) {
if (!flags.quiet) {
- error_s("cannot chown '%s': %s", get_path_buffer(), strerror(errno));
+ error_s("cannot chown '%s'", get_path_buffer());
}
pop_path_buffer(save);
return;
@@ -75,7 +74,7 @@ static void chown_file(char* path) {
if (lstat(get_path_buffer(), &s) < 0) {
if (!flags.quiet) {
- error_s("cannot stat '%s': %s", get_path_buffer(), strerror(errno));
+ error_s("cannot stat '%s'", get_path_buffer());
}
pop_path_buffer(save);
return;
@@ -89,7 +88,7 @@ static void chown_file(char* path) {
d = opendir(get_path_buffer());
if (d == NULL) {
if (!flags.quiet) {
- error_s("cannot open dir '%s': %s", get_path_buffer(), strerror(errno));
+ error_s("cannot open dir '%s'", get_path_buffer());
}
pop_path_buffer(save);
return;