[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1539359181.2656.13.camel@linux.ibm.com>
Date: Fri, 12 Oct 2018 08:46:21 -0700
From: James Bottomley <jejb@...ux.ibm.com>
To: Denis Kenzior <denkenz@...il.com>, ndesaulniers@...gle.com,
dhowells@...hat.com
Cc: natechancellor@...il.com, ebiggers@...gle.com,
Mimi Zohar <zohar@...ux.vnet.ibm.com>,
James Morris <jmorris@...ei.org>,
"Serge E. Hallyn" <serge@...lyn.com>,
linux-integrity@...r.kernel.org, keyrings@...r.kernel.org,
linux-security-module@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] KEYS: trusted: fix -Wvarags warning
On Fri, 2018-10-12 at 10:44 -0500, Denis Kenzior wrote:
> Hi James,
>
> > > So instead of having unsigned char h3, can't we simply have bool
> > > h3 or unsigned int h3?
> >
> > Given the ambiguity in the standards, the safe thing that will work
> > for all time and all potential compilers is a char *
> >
>
> All right. You state this with certainty, but I'd still like you to
> educate me why?
>
> From the links provided in the patch it seems that one cannot pass
> char/float/short to va_start(). Fair enough. So if we make h3 an
> unsigned int, the issue goes away, no?
For the current version of clang, yes. However, if we're fixing this
for good a char * pointer is the only guaranteed thing because it
mirrors current use in printf.
James
Powered by blists - more mailing lists