www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2002/05/25/10:05:01

From: Martin Stromberg <eplmst AT epl DOT ericsson DOT se>
Message-Id: <200205251323.PAA07405@lws256.lu.erisoft.se>
Subject: Re: refresh++
To: djgpp-workers AT delorie DOT com
Date: Sat, 25 May 2002 15:23:53 +0200 (MET DST)
In-Reply-To: <3CEF4E7B.17584050@phekda.freeserve.co.uk> from "Richard Dawe" at May 25, 2002 09:42:35 AM
X-Mailer: ELM [version 2.5 PL3]
MIME-Version: 1.0
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

Richard said:
> Andrew Cottrell wrote:
> [snip]
> > Please note that confstr.c as simple as I thought and I am wtill working on
> > it as the compiler does not like the following line in the file:-
> >       out_len = snprintf(buf, len, "");
> > GCC 3.1 complains about the third parameter.
> [snip]
> 
> What complaint does it have? I suspect it's complaining that there's no format
> string. Does it complain about this?
> 
>     out_len = snprintf(buf, len, "%s", "");
> 
> It looks like this call is intended to truncate the buffer, to return to an
> empty string.

What is this crap? Surely an empty format string is allowed and ok. I
suggest you find if there's a specific warning that can be switched
off and do that.


Right,

						MartinS

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019