diff options
author | Ondřej Vašík <ovasik@redhat.com> | 2008-03-10 17:03:41 +0100 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2008-03-10 19:47:15 +0100 |
commit | 9c393fa1944e5decb2838de7cbcf6b371717fd77 (patch) | |
tree | 2231be9b72506005a058543193e659120bb121c6 /src/rmdir.c | |
parent | 3c7a6ae340feee50ed6368ff9224aa3a29fff97e (diff) | |
download | coreutils-9c393fa1944e5decb2838de7cbcf6b371717fd77.tar.xz |
install, rmdir: write --verbose output to stdout, not to stderr.
* src/install.c (announce_mkdir): Write verbose output to stdout,
not to stderr.
* src/mkdir.c (announce mkdir): Use prog_fprintf for verbose output.
* src/prog-fprintf.c (prog_fprintf): New function and file.
* src/prog-fprintf.h: New file.
* src/rmdir.c (main): Write verbose output to stdout, not to stderr.
Quote directory name in a diagnostic.
* src/rmdir.c (remove_parents): Write verbose output to stdout,
not to stderr.
* doc/coreutils.texi: Mention that shred verbose output is to stderr.
* NEWS: Mention the changes.
Signed-off-by: Ondřej Vašík <ovasik@redhat.com>
Diffstat (limited to 'src/rmdir.c')
-rw-r--r-- | src/rmdir.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/rmdir.c b/src/rmdir.c index bb1a0c8b3..5f7f54116 100644 --- a/src/rmdir.c +++ b/src/rmdir.c @@ -1,6 +1,6 @@ /* rmdir -- remove directories - Copyright (C) 90, 91, 1995-2002, 2004, 2005, 2006, 2007 Free Software + Copyright (C) 90, 91, 1995-2002, 2004-2008 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify @@ -30,6 +30,7 @@ #include "system.h" #include "error.h" +#include "prog-fprintf.h" #include "quote.h" /* The official name of this program (e.g., no `g' prefix). */ @@ -134,7 +135,7 @@ remove_parents (char *dir) /* Give a diagnostic for each attempted removal if --verbose. */ if (verbose) - error (0, 0, _("removing directory, %s"), quote (dir)); + prog_fprintf (stdout, _("removing directory, %s"), quote (dir)); ok = (rmdir (dir) == 0); @@ -233,7 +234,7 @@ main (int argc, char **argv) /* Give a diagnostic for each attempted removal if --verbose. */ if (verbose) - error (0, 0, _("removing directory, %s"), dir); + prog_fprintf (stdout, _("removing directory, %s"), quote (dir)); if (rmdir (dir) != 0) { |