diff options
Diffstat (limited to 'src/wasm-interpreter.h')
-rw-r--r-- | src/wasm-interpreter.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wasm-interpreter.h b/src/wasm-interpreter.h index f34cb83be..377eb9465 100644 --- a/src/wasm-interpreter.h +++ b/src/wasm-interpreter.h @@ -1883,7 +1883,7 @@ public: const auto& ptrDataValues = ptrData->values; size_t startVal = start.getSingleValue().getUnsigned(); size_t endVal = end.getSingleValue().getUnsigned(); - if (endVal > ptrDataValues.size()) { + if (startVal > ptrDataValues.size() || endVal > ptrDataValues.size()) { trap("array oob"); } Literals contents; |