i965: don't crash on incorrect texture use
Cc: mesa-stable Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/4995 Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11603>
This commit is contained in:
parent
328ea8e04a
commit
02dd03ff3c
|
@ -104,6 +104,8 @@ brw_finalize_mipmap_tree(struct brw_context *brw,
|
|||
assert(!tObj->Immutable || brw->screen->devinfo.ver < 6);
|
||||
|
||||
firstImage = brw_texture_image(tObj->Image[0][tObj->Attrib.BaseLevel]);
|
||||
if (!firstImage)
|
||||
return;
|
||||
|
||||
/* Check tree can hold all active levels. Check tree matches
|
||||
* target, imageFormat, etc.
|
||||
|
|
Loading…
Reference in New Issue