diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2018-10-23 05:56:22 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2018-10-23 05:56:22 +0000 |
commit | 35351568863e9631d94e7cdbf0e466f45e06c32d (patch) | |
tree | 83570d384187b8d4e6982c4189921eacc12eaad2 /lib | |
parent | dd4051341642c02014e019ff356fe97b99aedf87 (diff) |
Import Mesa 17.3.9
Diffstat (limited to 'lib')
-rw-r--r-- | lib/mesa/src/compiler/blob.c | 9 | ||||
-rw-r--r-- | lib/mesa/src/compiler/blob.h | 6 |
2 files changed, 1 insertions, 14 deletions
diff --git a/lib/mesa/src/compiler/blob.c b/lib/mesa/src/compiler/blob.c index c89092e1c..8dd254fef 100644 --- a/lib/mesa/src/compiler/blob.c +++ b/lib/mesa/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; @@ -291,13 +291,6 @@ blob_copy_bytes(struct blob_reader *blob, void *dest, size_t size) memcpy(dest, bytes, size); } -void -blob_skip_bytes(struct blob_reader *blob, size_t size) -{ - if (ensure_can_read (blob, size)) - blob->current += size; -} - /* These next three read functions have identical form. If we add any beyond * these first three we should probably switch to generating these with a * preprocessor macro. diff --git a/lib/mesa/src/compiler/blob.h b/lib/mesa/src/compiler/blob.h index b56fa4b2f..2b975d45d 100644 --- a/lib/mesa/src/compiler/blob.h +++ b/lib/mesa/src/compiler/blob.h @@ -295,12 +295,6 @@ void blob_copy_bytes(struct blob_reader *blob, void *dest, size_t size); /** - * Skip \size bytes within the blob. - */ -void -blob_skip_bytes(struct blob_reader *blob, size_t size); - -/** * Read a uint32_t from the current location, (and update the current location * to just past this uint32_t). * |