[vlc-devel] [PATCH] libmp4: fix argument for formatting
ajanni at videolabs.io
Fri Mar 27 17:44:03 CET 2020
On Fri, Mar 27, 2020 at 06:29:36PM +0200, Rémi Denis-Courmont wrote:
> Le perjantaina 27. maaliskuuta 2020, 18.24.23 EET Alexandre Janniaux a écrit :
> > I know that va_arg promotes to int, but it has nothing to do
> > with the warning itself which is to ensure the format matches
> > the value given from the calling site. AFAIK the specification
> > doesn't specify the warnings.
> Whether such case grants a warning is subjective, and GCC devs seem to think
> that it does not.
> I don't see the point of this patch either way. This is dead code, and if you
> don't want it to warn, you can just use %u.
This is not dead code. MP4_VERBOSE is defined with the
/* Do you want some debug information on all read boxes ? */
# define MP4_VERBOSE 1
//# define MP4_ULTRA_VERBOSE 1
The fact it warns makes noise and diminish new or other
more important warnings, so either it should be silenced
globally or locally.
I'm fine with %u, so I'll switch to that if it matters to you.
More information about the vlc-devel