deps/obs-scripting: Set file/chunk name when loading lua scripts

This commit is contained in:
derrod 2023-05-11 22:17:10 +02:00 committed by Jim
parent 43c7742f8b
commit 82137de0bb

View file

@ -129,7 +129,8 @@ static bool load_lua_script(struct obs_lua_script *data)
goto fail;
}
if (luaL_loadbuffer(script, file_data, strlen(file_data), NULL) != 0) {
if (luaL_loadbuffer(script, file_data, strlen(file_data),
data->base.path.array) != 0) {
script_warn(&data->base, "Error loading file: %s",
lua_tostring(script, -1));
bfree(file_data);