nv50/ir: Initialize BuildUtil member tail.
authorVinson Lee <vlee@freedesktop.org>
Sat, 1 May 2021 01:03:09 +0000 (18:03 -0700)
committerMarge Bot <eric+marge@anholt.net>
Sat, 8 May 2021 01:21:35 +0000 (01:21 +0000)
Fix defect reported by Coverity Scan.

Uninitialized scalar field (UNINIT_CTOR)
uninit_member: Non-static class member tail is not initialized in
this constructor nor in any functions that it calls.

Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10561>

src/gallium/drivers/nouveau/codegen/nv50_ir_build_util.cpp

index 453d541..2fb02bb 100644 (file)
@@ -44,6 +44,8 @@ BuildUtil::init(Program *prog)
    bb = NULL;
    pos = NULL;
 
+   tail = false;
+
    memset(imms, 0, sizeof(imms));
    immCount = 0;
 }