mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 18:18:06 +02:00
disk_cache: Fix issue reading GLSL metadata
This would cause the read of the metadata content to fail, which would
prevent the linking from being skipped.
Seen on Rocket League with i965 shader cache.
Fixes: b86ecea344 "util/disk_cache: write cache item metadata to disk"
Cc: Timothy Arceri <tarceri@itsqueeze.com>
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
parent
e6ecd7d73f
commit
e5b141634c
1 changed files with 1 additions and 1 deletions
|
|
@ -1110,7 +1110,7 @@ disk_cache_get(struct disk_cache *cache, const cache_key key, size_t *size)
|
|||
* TODO: pass the metadata back to the caller and do some basic
|
||||
* validation.
|
||||
*/
|
||||
cache_item_md_size += sizeof(cache_key);
|
||||
cache_item_md_size += num_keys * sizeof(cache_key);
|
||||
ret = lseek(fd, num_keys * sizeof(cache_key), SEEK_CUR);
|
||||
if (ret == -1)
|
||||
goto fail;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue