Ignore unknown custom wasm sections.

This commit is contained in:
Dan Gohman
2018-02-26 15:24:25 -08:00
parent 2a26b70854
commit 81c126619b

View File

@@ -124,6 +124,10 @@ pub fn translate_module<'data>(
}
}
}
ParserState::BeginSection { code: SectionCode::Custom { .. }, .. } => {
// Ignore unknown custom sections.
next_input = ParserInput::SkipSection;
}
_ => return Err(String::from("wrong content in the preamble")),
};
}