[wasm] Let BranchTableIterator::has_next return false if decoder->failed()
R=titzer@chromium.org Review-Url: https://codereview.chromium.org/2411793006 Cr-Commit-Position: refs/heads/master@{#40287}
This commit is contained in:
parent
96a448aba3
commit
52cf416aa8
@ -234,7 +234,7 @@ struct BranchTableOperand {
|
||||
class BranchTableIterator {
|
||||
public:
|
||||
unsigned cur_index() { return index_; }
|
||||
bool has_next() { return index_ <= table_count_; }
|
||||
bool has_next() { return decoder_->ok() && index_ <= table_count_; }
|
||||
uint32_t next() {
|
||||
DCHECK(has_next());
|
||||
index_++;
|
||||
|
Loading…
Reference in New Issue
Block a user