mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-04 17:50:11 +01:00
glsl: Fix null check in read_dereference.
Fixes "Logically dead code" defect reported by Coverity. Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Brian Paul <brianp@vmware.com>
This commit is contained in:
parent
399548b17f
commit
93534873b0
1 changed files with 1 additions and 1 deletions
|
|
@ -886,7 +886,7 @@ ir_reader::read_dereference(s_expression *expr)
|
|||
}
|
||||
|
||||
ir_rvalue *idx = read_rvalue(s_index);
|
||||
if (subject == NULL) {
|
||||
if (idx == NULL) {
|
||||
ir_read_error(NULL, "when reading the index of an array_ref");
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue