This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: error: format string argument not a string type
- From: Ian Lance Taylor <iant at google dot com>
- To: Kalle Olavi Niemitalo <kon at iki dot fi>
- Cc: gcc-help at gcc dot gnu dot org, elinks-dev at linuxfromscratch dot org
- Date: Tue, 17 Mar 2009 06:52:36 -0700
- Subject: Re: error: format string argument not a string type
- References: <87sklcbmsu.fsf@Astalo.kon.iki.fi>
Kalle Olavi Niemitalo <kon@iki.fi> writes:
> If I change the unsigned char * to char *, then this error goes
> away. But is there any other way to make GCC check the format
> arguments without this error?
Not without changing your source code.
Perhaps you could use a varargs macro to cast the pointer to the
required type.
Ian