bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] test-readtokens.c: avoid const-related compilation warnings


From: Bruno Haible
Subject: Re: [PATCH] test-readtokens.c: avoid const-related compilation warnings
Date: Thu, 08 Mar 2012 11:56:29 +0100
User-agent: KMail/4.7.4 (Linux/3.1.0-1.2-desktop; KDE/4.7.4; x86_64; ; )

Jim Meyering wrote:
> @@ -77,7 +77,7 @@ main (int argc, char **argv)
> 
>    if (STREQ (delim, "\\0"))
>      {
> -      delim = "";
> +      delim = (char *) "";
>        delim_len = 1;
>      }
> 

Instead of introducing this cast, how about making 'delim' a 'const char *'?
I see no code that writes into 'delim'.

Bruno




reply via email to

[Prev in Thread] Current Thread [Next in Thread]