mirror of
https://github.com/mii443/wasmer.git
synced 2025-12-08 21:58:20 +00:00
Make Module compilation safe
This commit is contained in:
@@ -136,7 +136,7 @@ impl Module {
|
|||||||
store.engine().validate(binary)
|
store.engine().validate(binary)
|
||||||
}
|
}
|
||||||
|
|
||||||
unsafe fn compile(store: &Store, binary: &[u8]) -> Result<Self, CompileError> {
|
fn compile(store: &Store, binary: &[u8]) -> Result<Self, CompileError> {
|
||||||
let compiled = store.engine().compile(binary)?;
|
let compiled = store.engine().compile(binary)?;
|
||||||
Ok(Self::from_compiled_module(store, compiled))
|
Ok(Self::from_compiled_module(store, compiled))
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user