From 263c26e4d1b87a98aa8b97c8d5b707fd8e6b6bb8 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Thu, 6 Nov 2014 21:27:59 -0600 Subject: maint: add three casts-in-initialization to avoid warnings * sed/compile.c (special_files): When initializing, cast string literals to (char *) to avoid warnings. --- sed/compile.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sed/compile.c b/sed/compile.c index 0e9eec6..3b9264b 100644 --- a/sed/compile.c +++ b/sed/compile.c @@ -80,10 +80,10 @@ struct special_files { }; static FILE *my_stdin, *my_stdout, *my_stderr; -static const struct special_files special_files[] = { - { { "/dev/stdin", false, NULL, NULL }, &my_stdin }, - { { "/dev/stdout", false, NULL, NULL }, &my_stdout }, - { { "/dev/stderr", false, NULL, NULL }, &my_stderr }, +static struct special_files special_files[] = { + { { (char *) "/dev/stdin", false, NULL, NULL }, &my_stdin }, + { { (char *) "/dev/stdout", false, NULL, NULL }, &my_stdout }, + { { (char *) "/dev/stderr", false, NULL, NULL }, &my_stderr }, { { NULL, false, NULL, NULL }, NULL } }; -- cgit v1.2.1