> -----Original Message----- > From: Philippe Mathieu-Daudé <philippe.mathieu.da...@gmail.com> On > Behalf Of Philippe Mathieu-Daudé > Sent: Tuesday, February 23, 2021 5:13 AM > To: qemu-devel@nongnu.org > Cc: Richard Henderson <richard.hender...@linaro.org>; Taylor Simpson > <tsimp...@quicinc.com>; Philippe Mathieu-Daudé <f4...@amsat.org> > Subject: [PATCH] target/hexagon/opcodes: Add missing varargs cleanup > > Fix a trivial incorrect usage of variable argument macros detected > by Coverity (missing_va_end: va_end was not called for ap). > > Fixes: Coverity CID 1446720 (VARARGS) > Fixes: e3c00c2ed75 ("Hexagon (target/hexagon) opcode data structures") > Signed-off-by: Philippe Mathieu-Daudé <f4...@amsat.org> > --- > target/hexagon/opcodes.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/target/hexagon/opcodes.c b/target/hexagon/opcodes.c > index 4eef5fc40f6..35d790cdd5b 100644 > --- a/target/hexagon/opcodes.c > +++ b/target/hexagon/opcodes.c > @@ -82,6 +82,7 @@ static void init_attribs(int tag, ...) > while ((attr = va_arg(ap, int)) != 0) { > set_bit(attr, opcode_attribs[tag]); > } > + va_end(ap); > } >
Reviewed-by: Taylor Simpson <tsimp...@quicinc.com> Tested-by: Taylor Simpson <tsimp...@quicinc.com>