Closed
Description
Hi. I'm trying out the mlua lib. I don't know if I did something wrong, but aborting with a SIGILL doesn't seem like intended behavior.
The crash happens When I create the lua object with Lua::new_with(StdLib::NONE, ...)
, but not when creating it with Lua::new_with(StdLib::ALL_SAFE, ...)
or Lua::new()
.
This is how I imported mlua in Cargo.toml:
mlua = { version = "0.9.4", features = ["luau", "vendored", "async", "serialize"] }
This is src/main.rs:
use std::fs;
use mlua::{Lua, StdLib, LuaOptions};
fn main() -> mlua::Result<()> {
let lua = Lua::new_with(StdLib::NONE, LuaOptions::default())?;
// let lua = Lua::new();
lua.sandbox(true)?;
let lua_code = fs::read_to_string("./test.lua")?;
lua.load(lua_code).exec()?;
Ok(())
}
And this is the test.lua file:
print('hello world')
And this is the core dump: coredump.gz
Metadata
Metadata
Assignees
Labels
No labels