diff options
author | Pádraig Brady <P@draigBrady.com> | 2015-08-16 16:47:17 +0100 |
---|---|---|
committer | Pádraig Brady <P@draigBrady.com> | 2015-09-03 01:11:32 +0100 |
commit | 895a56c53118ea1ed97e0641a413ca4793afaa20 (patch) | |
tree | 045e10cc7014c17686290859ca935d36d1461aa6 /src/ptx.c | |
parent | df3b9120b4b0444bedbe53ef7a2cc5bb28fb3943 (diff) | |
download | coreutils-895a56c53118ea1ed97e0641a413ca4793afaa20.tar.xz |
ls,ptx: restrict quotearg use to file name output
* src/ls.c (getenv_quoting_style, decode_switches, parse_ls_color):
Use quote() rather than quotearg(), as the latter defaults to
outputting the input unquoted.
* src/ptx.c (main): Likewise.
Diffstat (limited to 'src/ptx.c')
-rw-r--r-- | src/ptx.c | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -28,7 +28,6 @@ #include "error.h" #include "fadvise.h" #include "quote.h" -#include "quotearg.h" #include "read-file.h" #include "stdio--.h" #include "xstrtol.h" @@ -1949,7 +1948,7 @@ main (int argc, char **argv) if (xstrtoul (optarg, NULL, 0, &tmp_ulong, NULL) != LONGINT_OK || ! (0 < tmp_ulong && tmp_ulong <= INT_MAX)) error (EXIT_FAILURE, 0, _("invalid gap width: %s"), - quotearg (optarg)); + quote (optarg)); gap_size = tmp_ulong; break; } @@ -1976,7 +1975,7 @@ main (int argc, char **argv) if (xstrtoul (optarg, NULL, 0, &tmp_ulong, NULL) != LONGINT_OK || ! (0 < tmp_ulong && tmp_ulong <= INT_MAX)) error (EXIT_FAILURE, 0, _("invalid line width: %s"), - quotearg (optarg)); + quote (optarg)); line_width = tmp_ulong; break; } |