svga: move variant->fs_shadow_compare_units assignment

Fixes a crash since the variant object isn't allocated until later
in the function.  Not sure how this got through.

Reviewed-by: Charmaine Lee <charmainel@vmware.com>
This commit is contained in:
Brian Paul 2017-12-27 11:36:03 -07:00
parent cb70474b20
commit c174ee9f9d
1 changed files with 2 additions and 0 deletions

View File

@ -7107,6 +7107,8 @@ svga_tgsi_vgpu10_translate(struct svga_context *svga,
variant->fs_shadow_compare_units = emit->fs.shadow_compare_units;
variant->fs_shadow_compare_units = emit->fs.shadow_compare_units;
if (tokens != shader->tokens) {
tgsi_free_tokens(tokens);
}