forked from OSchip/llvm-project
[WebAssembly] Fix asan issue from https://reviews.llvm.org/D121349
This commit is contained in:
parent
98dd390573
commit
2481adb59c
|
@ -1474,6 +1474,7 @@ Error WasmObjectFile::parseElemSection(ReadContext &Ctx) {
|
|||
object_error::parse_failed);
|
||||
|
||||
if (Segment.Flags & wasm::WASM_ELEM_SEGMENT_IS_PASSIVE) {
|
||||
Segment.Offset.Extended = false;
|
||||
Segment.Offset.Inst.Opcode = wasm::WASM_OPCODE_I32_CONST;
|
||||
Segment.Offset.Inst.Value.Int32 = 0;
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue