From: Michael Tokarev <mjt@tls.msk.ru>
To: Stefan Weil <sw@weilnetz.de>
Cc: qemu-trivial@nongnu.org, qemu-devel <qemu-devel@nongnu.org>,
Anthony Liguori <aliguori@amazon.com>
Subject: Re: [Qemu-trivial] [PATCH for 1.7] acpi-build: Fix compiler warning (missing gnu_printf format attribute)
Date: Wed, 20 Nov 2013 15:53:18 +0400 [thread overview]
Message-ID: <528CA2AE.6050303@msgid.tls.msk.ru> (raw)
In-Reply-To: <1384711222-8916-1-git-send-email-sw@weilnetz.de>
17.11.2013 22:00, Stefan Weil wrote:
> gcc 4.8.2 reports this warning when extra warnings are enabled (-Wextra):
>
> CC m68k-softmmu/hw/m68k/mcf5206.o
> hw/i386/acpi-build.c: In function ‘build_append_nameseg’:
> hw/i386/acpi-build.c:294:5: error:
> function might be possible candidate for ‘gnu_printf’ format attribute [-Werror=suggest-attribute=format]
> g_string_vprintf(s, format, args);
> ^
>
> When this warning is fixed, there is a new compiler warning:
>
> CC i386-softmmu/hw/i386/acpi-build.o
> hw/i386/acpi-build.c: In function ‘build_append_notify’:
> hw/i386/acpi-build.c:632:5: error:
> format not a string literal and no format arguments [-Werror=format-security]
> build_append_nameseg(method, name);
> ^
>
> This is fixed here, too.
Thanks, applied to the trivial-patches queue.
Note this patch also triggers checkpatch.pl error:
> +static void GCC_FMT_ATTR(2, 3)
> +build_append_nameseg(GArray *array, const char *format, ...)
^
ERROR: need consistent spacing around '*' (ctx:WxV)
#40: FILE: hw/i386/acpi-build.c:289:
It looks like checkpatch.pl needs some tweaking here, because
the spacing here is really consistent, as far as I can see.
/mjt
WARNING: multiple messages have this Message-ID (diff)
From: Michael Tokarev <mjt@tls.msk.ru>
To: Stefan Weil <sw@weilnetz.de>
Cc: qemu-trivial@nongnu.org, qemu-devel <qemu-devel@nongnu.org>,
Anthony Liguori <aliguori@amazon.com>
Subject: Re: [Qemu-devel] [Qemu-trivial] [PATCH for 1.7] acpi-build: Fix compiler warning (missing gnu_printf format attribute)
Date: Wed, 20 Nov 2013 15:53:18 +0400 [thread overview]
Message-ID: <528CA2AE.6050303@msgid.tls.msk.ru> (raw)
In-Reply-To: <1384711222-8916-1-git-send-email-sw@weilnetz.de>
17.11.2013 22:00, Stefan Weil wrote:
> gcc 4.8.2 reports this warning when extra warnings are enabled (-Wextra):
>
> CC m68k-softmmu/hw/m68k/mcf5206.o
> hw/i386/acpi-build.c: In function ‘build_append_nameseg’:
> hw/i386/acpi-build.c:294:5: error:
> function might be possible candidate for ‘gnu_printf’ format attribute [-Werror=suggest-attribute=format]
> g_string_vprintf(s, format, args);
> ^
>
> When this warning is fixed, there is a new compiler warning:
>
> CC i386-softmmu/hw/i386/acpi-build.o
> hw/i386/acpi-build.c: In function ‘build_append_notify’:
> hw/i386/acpi-build.c:632:5: error:
> format not a string literal and no format arguments [-Werror=format-security]
> build_append_nameseg(method, name);
> ^
>
> This is fixed here, too.
Thanks, applied to the trivial-patches queue.
Note this patch also triggers checkpatch.pl error:
> +static void GCC_FMT_ATTR(2, 3)
> +build_append_nameseg(GArray *array, const char *format, ...)
^
ERROR: need consistent spacing around '*' (ctx:WxV)
#40: FILE: hw/i386/acpi-build.c:289:
It looks like checkpatch.pl needs some tweaking here, because
the spacing here is really consistent, as far as I can see.
/mjt
next prev parent reply other threads:[~2013-11-20 11:53 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-17 18:00 [Qemu-trivial] [PATCH for 1.7] acpi-build: Fix compiler warning (missing gnu_printf format attribute) Stefan Weil
2013-11-17 18:00 ` [Qemu-devel] " Stefan Weil
2013-11-17 20:40 ` [Qemu-trivial] " Michael Tokarev
2013-11-17 20:40 ` [Qemu-devel] " Michael Tokarev
2013-11-17 21:55 ` Stefan Weil
2013-11-17 21:55 ` [Qemu-devel] " Stefan Weil
2013-11-20 11:53 ` Michael Tokarev [this message]
2013-11-20 11:53 ` Michael Tokarev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=528CA2AE.6050303@msgid.tls.msk.ru \
--to=mjt@tls.msk.ru \
--cc=aliguori@amazon.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
--cc=sw@weilnetz.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.