summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPádraig Brady <P@draigBrady.com>2009-09-01 13:02:13 +0200
committerJim Meyering <meyering@redhat.com>2009-09-01 13:05:06 +0200
commit1b2d2635eeabce4a2176427dc1de9c1b9b87bc7d (patch)
tree81dea34b525734b40df71eb9507220b30e31344b /src
parentfa3e9cb9afa122fe12ed3baf53225a15d5bb10b5 (diff)
downloadcoreutils-1b2d2635eeabce4a2176427dc1de9c1b9b87bc7d.tar.xz
chcon, chmod, chgrp, chown, du: report fts_close failure
* src/du.c (du_files): Don't fail silently upon fts_close failure. * src/chcon.c (process_files): Likewise. * src/chmod.c (process_files): Likewise. * src/chown-core.c (chown_files): Likewise.
Diffstat (limited to 'src')
-rw-r--r--src/chcon.c5
-rw-r--r--src/chmod.c5
-rw-r--r--src/chown-core.c5
-rw-r--r--src/du.c5
4 files changed, 16 insertions, 4 deletions
diff --git a/src/chcon.c b/src/chcon.c
index 83d0583f8..7e8250d3d 100644
--- a/src/chcon.c
+++ b/src/chcon.c
@@ -325,7 +325,10 @@ process_files (char **files, int bit_flags)
}
if (fts_close (fts) != 0)
- ok = false;
+ {
+ error (0, errno, _("fts_close failed"));
+ ok = false;
+ }
return ok;
}
diff --git a/src/chmod.c b/src/chmod.c
index 0688979df..282eadaff 100644
--- a/src/chmod.c
+++ b/src/chmod.c
@@ -336,7 +336,10 @@ process_files (char **files, int bit_flags)
}
if (fts_close (fts) != 0)
- ok = false;
+ {
+ error (0, errno, _("fts_close failed"));
+ ok = false;
+ }
return ok;
}
diff --git a/src/chown-core.c b/src/chown-core.c
index 82e96442a..705a29bd3 100644
--- a/src/chown-core.c
+++ b/src/chown-core.c
@@ -510,7 +510,10 @@ chown_files (char **files, int bit_flags,
}
if (fts_close (fts) != 0)
- ok = false;
+ {
+ error (0, errno, _("fts_close failed"));
+ ok = false;
+ }
return ok;
}
diff --git a/src/du.c b/src/du.c
index 16a7b9b3e..9da901a62 100644
--- a/src/du.c
+++ b/src/du.c
@@ -643,7 +643,10 @@ du_files (char **files, int bit_flags)
}
if (fts_close (fts) != 0)
- ok = false;
+ {
+ error (0, errno, _("fts_close failed"));
+ ok = false;
+ }
}
return ok;