[Mesa-dev] [PATCH v3 18/34] blob: Don't set overrun if reading 0 bytes at end of data
Jordan Justen
jordan.l.justen at intel.com
Sun Oct 22 20:01:26 UTC 2017
Signed-off-by: Jordan Justen <jordan.l.justen at intel.com>
---
src/compiler/blob.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/compiler/blob.c b/src/compiler/blob.c
index 8dd254fefc6..5e8671b7b44 100644
--- a/src/compiler/blob.c
+++ b/src/compiler/blob.c
@@ -256,7 +256,7 @@ ensure_can_read(struct blob_reader *blob, size_t size)
if (blob->overrun)
return false;
- if (blob->current < blob->end && blob->end - blob->current >= size)
+ if (blob->current <= blob->end && blob->end - blob->current >= size)
return true;
blob->overrun = true;
--
2.15.0.rc0
More information about the mesa-dev
mailing list