mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 05:18:08 +02:00
tgsi_to_nir: free disk cache value if the size is wrong
Fixes:4db880d805("ttn: Implement disk cache") Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Rob Clark <robclark@freedesktop.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30308> (cherry picked from commit11bc95934f)
This commit is contained in:
parent
9c3d3f0e55
commit
271b6d1cf6
2 changed files with 2 additions and 1 deletions
|
|
@ -304,7 +304,7 @@
|
|||
"description": "tgsi_to_nir: free disk cache value if the size is wrong",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": "4db880d8057bac3209c196edc94c6b1e521a782a",
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -2600,6 +2600,7 @@ load_nir_from_disk_cache(struct disk_cache *cache,
|
|||
* However we do still check if the first element is indeed the size,
|
||||
* as we cannot fully trust disk_cache_get (EGL_ANDROID_blob_cache) */
|
||||
if (buffer[0] != size) {
|
||||
free(buffer);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue