glsl/blob: Return false from ensure_can_read on overrun
authorJason Ekstrand <jason.ekstrand@intel.com>
Wed, 11 Oct 2017 17:56:48 +0000 (10:56 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Fri, 13 Oct 2017 04:47:06 +0000 (21:47 -0700)
commit7118851374074bd92887bfabd47ce39c9be412fd
treedb9d2f23a0d5c0179d2b6c5c5c8b804d463a5a0f
parentc866e0b3ca563de579d0231278239aa6427c9ddf
glsl/blob: Return false from ensure_can_read on overrun

Otherwise, if you have a large read fail and then try to do a small
read, the small read may succeed even though it's at the wrong offset.

Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Cc: mesa-stable@lists.freedesktop.org
src/compiler/glsl/blob.c