blob: Don't set overrun if reading 0 bytes at end of data
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
This commit is contained in:
@@ -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;
|
||||
|
Reference in New Issue
Block a user