Dag-Erling Smorgrav wrote:
> Bruce Evans <[EMAIL PROTECTED]> writes:
> > The main bug is that the warning is emitted.  err(1, NULL) is perfectly
> > valid (see err(4)).  Apparently the sparc64 compiler is missing support
> > for __printf0like.
> 
> Strangely, my Alpha (July 3 -CURRENT) complains about this too, but my
> i386 (June 24 -CURRENT) doesn't.  Here's my test program:
> 
> #include <stdio.h>
> 
> int
> main(void)
> {
>         printf(NULL);
>         return 0;
> }
> 
> on Alpha, I get
> 
> des@dsa ~% gcc -Wformat -c /tmp/format.c
> /tmp/format.c: In function `main':
> /tmp/format.c:6: warning: null format string
> 
> on i386, I don't get a warning.

Stranger and stranger..  On sparc64 from:

peter@panther[4:21pm]~-104> uname -a
FreeBSD panther.freebsd.org FreeBSD 5.0-CURRENT #2: Sun Jul  7 20:52:14 PDT 2002er
peter@panther[4:21pm]~-105> cat foo.c
#include <stdio.h>
#include <err.h>

int
main(void)
{
        printf(NULL);
        err(1, NULL);
        return 0;
}

peter@panther[4:22pm]~-106> cc -O -Wformat -c foo.c
peter@panther[4:22pm]~-107> 

ie: it looks like it is completely disabled. Maybe the sparc64 tinderbox
host is simply out of sync with -current?

Cheers,
-Peter
--
Peter Wemm - [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED]
"All of this is for nothing if we don't go to the stars" - JMS/B5


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to