From: Bertrand Marquis <Bertrand.Marquis@arm.com>
To: Wei Liu <wl@xen.org>
Cc: "xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>,
Ian Jackson <iwj@xenproject.org>
Subject: Re: [PATCH v3] tools/xenpmd: Fix gcc10 snprintf warning
Date: Fri, 16 Oct 2020 13:43:48 +0000 [thread overview]
Message-ID: <E8ECEA42-842F-4F66-BF86-1FB5F787D906@arm.com> (raw)
In-Reply-To: <20201016132833.fadg2dtj2q6pshrj@liuwe-devbox-debian-v2>
> On 16 Oct 2020, at 14:28, Wei Liu <wl@xen.org> wrote:
>
> On Thu, Oct 15, 2020 at 10:16:09AM +0100, Bertrand Marquis wrote:
>> Add a check for snprintf return code and ignore the entry if we get an
>> error. This should in fact never happen and is more a trick to make gcc
>> happy and prevent compilation errors.
>>
>> This is solving the following gcc warning when compiling for arm32 host
>> platforms with optimization activated:
>> xenpmd.c:92:37: error: '%s' directive output may be truncated writing
>> between 4 and 2147483645 bytes into a region of size 271
>> [-Werror=format-truncation=]
>>
>> This is also solving the following Debian bug:
>> https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=970802
>>
>> Signed-off-by: Bertrand Marquis <bertrand.marquis@arm.com>
>
> Acked-by: Wei Liu <wl@xen.org>
Thanks :-)
Bertrand
prev parent reply other threads:[~2020-10-16 13:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-15 9:16 [PATCH v3] tools/xenpmd: Fix gcc10 snprintf warning Bertrand Marquis
2020-10-16 13:28 ` Wei Liu
2020-10-16 13:43 ` Bertrand Marquis [this message]
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=E8ECEA42-842F-4F66-BF86-1FB5F787D906@arm.com \
--to=bertrand.marquis@arm.com \
--cc=iwj@xenproject.org \
--cc=wl@xen.org \
--cc=xen-devel@lists.xenproject.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).