si_descriptor: move velems nullity check before dereference
authorJulien Isorce <jisorce@oblong.com>
Thu, 16 Mar 2017 13:09:21 +0000 (13:09 +0000)
committerJulien Isorce <jisorce@oblong.com>
Mon, 20 Mar 2017 18:01:51 +0000 (18:01 +0000)
commita6e212440278df2bb0766a5cf745935d94809144
treea7f198b75e4071a1e9dc94e3fcffe729a9083724
parent521860b2a92bab6394546e6af8709c07e2292033
si_descriptor: move velems nullity check before dereference

CID 1399479: Dereference before null check (REVERSE_INULL)
check_after_deref: Null-checking velems suggests that it may be null,
but it has already been dereferenced on all paths leading to the check.

Signed-off-by: Julien Isorce <jisorce@oblong.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/gallium/drivers/radeonsi/si_descriptors.c