summaryrefslogtreecommitdiff
path: root/src/shred.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2005-07-03 07:19:29 +0000
committerPaul Eggert <eggert@cs.ucla.edu>2005-07-03 07:19:29 +0000
commitce00cad00f1de8822c246037882a68facf131751 (patch)
treef3084bc4fddd947f9017af5d63c66b7164370d43 /src/shred.c
parent8359085a7606bf035dab89aad445dd0320b08ad4 (diff)
downloadcoreutils-ce00cad00f1de8822c246037882a68facf131751.tar.xz
Include fcntl--.h, not unistd-safer.h.
(wipename, wipe_file): Don't use fd_safer; no longer needed now that we include fcntl--.h.
Diffstat (limited to 'src/shred.c')
-rw-r--r--src/shred.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/shred.c b/src/shred.c
index 3348ff4f7..8a1d114bd 100644
--- a/src/shred.c
+++ b/src/shred.c
@@ -102,13 +102,13 @@
#include "xstrtol.h"
#include "dirname.h"
#include "error.h"
+#include "fcntl--.h"
#include "gethrxtime.h"
#include "getpagesize.h"
#include "human.h"
#include "inttostr.h"
#include "quotearg.h" /* For quotearg_colon */
#include "quote.h" /* For quotearg_colon */
-#include "unistd-safer.h"
#define DEFAULT_PASSES 25 /* Default */
@@ -1354,7 +1354,6 @@ wipename (char *oldname, char const *qoldname, struct Options const *flags)
int dir_fd = open (dir, O_WRONLY | O_NOCTTY);
if (dir_fd < 0)
dir_fd = open (dir, O_RDONLY | O_NOCTTY);
- dir_fd = fd_safer (dir_fd);
if (flags->verbose)
error (0, 0, _("%s: removing"), qoldname);
@@ -1448,7 +1447,6 @@ wipefile (char *name, char const *qname,
&& (errno == EACCES && flags->force)
&& chmod (name, S_IWUSR) == 0)
fd = open (name, O_WRONLY | O_NOCTTY);
- fd = fd_safer (fd);
if (fd < 0)
{
error (0, errno, _("%s: failed to open for writing"), qname);