diff options
author | Pádraig Brady <P@draigBrady.com> | 2015-10-28 13:02:31 +0000 |
---|---|---|
committer | Pádraig Brady <P@draigBrady.com> | 2015-11-04 02:03:41 +0000 |
commit | ab40a941a07d80326aaa051e3c94c88b800cbd7d (patch) | |
tree | 382e656f126d0e63ca1158f8f43630e1dd10d18b /src/ls.c | |
parent | 00eb7af8ea30ccbefeb17213cd644b8f0ade1ef8 (diff) | |
download | coreutils-ab40a941a07d80326aaa051e3c94c88b800cbd7d.tar.xz |
all: replace most uses of quotearg_colon() with quote()
Related to commit v8.24-61-g6796698 this provides
more consistent quoting, as quotearg_colon() defaults
to "literal" quoting by default, while quote()
provides appropriate quoting for diagnostics by default.
* gl/modules/randread: Depend on quote module rather than quotearg.
* gl/lib/randread.c: Used quote() not quotearg_colon().
* src/: Likewise.
* src/shred.c: Likewise. Also avoid unnecessary quoting
introducing overhead when wiping names.
* cfg.mk: Relax the matching expression to allow
"qname" variables as used in shred.c to satisfy the check.
* tests/: Adjust accordingly.
Diffstat (limited to 'src/ls.c')
-rw-r--r-- | src/ls.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -2534,7 +2534,7 @@ set_exit_status (bool serious) static void file_failure (bool serious, char const *message, char const *file) { - error (0, errno, message, quotearg_colon (file)); + error (0, errno, message, quote (file)); set_exit_status (serious); } @@ -2601,7 +2601,7 @@ print_dir (char const *name, char const *realname, bool command_line_arg) if (visit_dir (dir_stat.st_dev, dir_stat.st_ino)) { error (0, 0, _("%s: not listing already-listed directory"), - quotearg_colon (name)); + quote (name)); closedir (dirp); set_exit_status (true); return; @@ -3109,7 +3109,7 @@ gobble_file (char const *name, enum filetype type, ino_t inode, any_has_acl |= f->acl_type != ACL_T_NONE; if (err) - error (0, errno, "%s", quotearg_colon (absolute_name)); + error (0, errno, "%s", quote (absolute_name)); } if (S_ISLNK (f->stat.st_mode) |