This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/47781] warnings from custom printf format specifiers
- From: "mark-gcc at glines dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 17 Feb 2011 11:58:29 +0000
- Subject: [Bug c/47781] warnings from custom printf format specifiers
- Auto-submitted: auto-generated
- References: <bug-47781-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47781
--- Comment #2 from Mark Glines <mark-gcc at glines dot org> 2011-02-17 11:58:22 UTC ---
Created attachment 23380
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=23380
47781.c
Here's a rather silly test case that demonstrates the problem with a simple
"bool" type.
$ gcc -O2 -Wall -o 47781 47781.c
47781.c: In function âmainâ:
47781.c:12: warning: unknown conversion type character âbâ in format
47781.c:12: warning: unknown conversion type character âbâ in format
47781.c:12: warning: too many arguments for format
$ ./47781
true bool: TRUE false bool: FALSE
$
(That's on x86-64 linux with gcc 4.4.4-14ubuntu5 and libc6 2.12.1-0ubuntu10.2.)