summaryrefslogtreecommitdiff
path: root/src/pr.c
diff options
context:
space:
mode:
authorJim Meyering <meyering@redhat.com>2008-10-28 22:06:44 +0100
committerJim Meyering <meyering@redhat.com>2008-11-10 08:11:59 +0100
commit854284f7887677395239c1085b27a09e834291b7 (patch)
treec719e6ee13b41342e70faa7bf6f8e3bc0acdbfd1 /src/pr.c
parent0e2ac2de24b2d64924826a693630d8d555beae3a (diff)
downloadcoreutils-854284f7887677395239c1085b27a09e834291b7.tar.xz
avoid warnings about discarding "qualifiers from pointer target type"
Use the new "bad_cast" function or an actual cast-to-"(char *)" to avoid warnings. * src/system.h (bad_cast): Define. * src/chown.c (main): * src/chroot.c (main): * src/date.c (main): * src/du.c (main): * src/expand.c (stdin_argv): * src/ls.c (decode_switches): * src/md5sum.c (main): * src/paste.c (main): * src/pr.c (col_sep_string, column_separator, line_separator, main): * src/sort.c (main): * src/split.c (main): * src/tail.c (main): * src/unexpand.c (stdin_argv): * src/yes.c (main):
Diffstat (limited to 'src/pr.c')
-rw-r--r--src/pr.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/pr.c b/src/pr.c
index 0d8845fe6..044bb5609 100644
--- a/src/pr.c
+++ b/src/pr.c
@@ -691,10 +691,10 @@ static bool use_col_separator = false;
/* String used to separate columns if the -S option has been specified.
Default without -S but together with one of the column options
-a|COLUMN|-m is a `space' and with the -J option a `tab'. */
-static char *col_sep_string = "";
+static char *col_sep_string = (char *) "";
static int col_sep_length = 0;
-static char *column_separator = " ";
-static char *line_separator = "\t";
+static char *column_separator = (char *) " ";
+static char *line_separator = (char *) "\t";
/* Number of separator characters waiting to be printed as soon as we
know that we have any input remaining to be printed. */
@@ -1030,7 +1030,7 @@ main (int argc, char **argv)
case 'S':
old_s = false;
/* Reset an additional input of -s, -S dominates -s */
- col_sep_string = "";
+ col_sep_string = bad_cast ("");
col_sep_length = 0;
use_col_separator = true;
if (optarg)