This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: eliminate warnings in printcmd.c


On Fri, Dec 10, 2004 at 03:06:50PM +1100, Ben Elliston wrote:
> This patch eliminates warnings whereby the format string is not a
> string literal and GCC cannot check it at compile-time.  I don't
> expect this patch to be tremendously popular, but my hope is that it
> will stimulate some discussion on how to really fix it :-)

It wouldn't be hard to do.  The flow of printf_command is fairly
simple; part of each substring could be replaced by puts, and the rest
by printf with fixed format strings using %*.*.  You're welcome to
implement that ;-)

-- 
Daniel Jacobowitz


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]