[pulseaudio-discuss] coverity and pa_asser_se

Felipe Sateler fsateler at debian.org
Mon Sep 21 15:50:58 PDT 2015


Hi,

On 15 September 2015 at 19:01, Peter Meerwald <pmeerw at pmeerw.net> wrote:
> nota bene: put the following in user_nodefs.h in the cov-analysis/config
> directory to address pa_assert_se() false alarms:
>
>  #nodef pa_assert_se(x) do { int y = x ; if (!(y)) __coverity_panic__(); } while (0)

This indeed fixes the problem, but introduces a new one (although
rarer). See CID 1324353, where coverity complains about an
uninitialized variable y is used. I suggest replacing the variable
names with less common ones.

#nodef pa_assert_se(expr1234) do { int result1234 = expr1234 ; if
(!(result1234)) __coverity_panic__(); } while (0)


-- 

Saludos,
Felipe Sateler


More information about the pulseaudio-discuss mailing list