diff options
-rw-r--r-- | coreutils/shred.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/coreutils/shred.c b/coreutils/shred.c index 4b95d19..04bf872 100644 --- a/coreutils/shred.c +++ b/coreutils/shred.c @@ -99,12 +99,12 @@ int shred_main(int argc UNUSED_PARAM, char **argv) bb_copyfd_size(zero_fd, fd, size); fdatasync(fd); } - if (opt & OPT_u) { - ftruncate(fd, 0); - xunlink(fname); - } - xclose(fd); } + if (opt & OPT_u) { + ftruncate(fd, 0); + xunlink(fname); + } + xclose(fd); } return EXIT_SUCCESS; |