[WebAssembly] Fix faulty logic in verifyRelocTargets

This commit is contained in:
Wouter van Oortmerssen 2020-04-16 18:19:29 -07:00
parent 634f173830
commit cbf99e0fba
1 changed files with 1 additions and 1 deletions

View File

@ -78,7 +78,7 @@ void InputChunk::verifyRelocTargets() const {
if (bytesRead && bytesRead != 5)
warn("expected LEB at relocation site be 5-byte padded");
if (rel.Type != R_WASM_GLOBAL_INDEX_LEB ||
if (rel.Type != R_WASM_GLOBAL_INDEX_LEB &&
rel.Type != R_WASM_GLOBAL_INDEX_I32) {
uint32_t expectedValue = file->calcExpectedValue(rel);
if (expectedValue != existingValue)