mirror of
https://github.com/mt-mods/pipeworks.git
synced 2024-11-09 17:03:58 +01:00
Merge branch 'master' into 'master'
Fix crash when lua tubes are DoSed. See merge request VanessaE/pipeworks!8
This commit is contained in:
commit
27eb2ca9de
@ -333,8 +333,11 @@ local safe_globals = {
|
||||
}
|
||||
|
||||
local function create_environment(pos, mem, event)
|
||||
-- Gather variables for the environment
|
||||
-- Make sure the tube hasn't broken.
|
||||
local vports = minetest.registered_nodes[minetest.get_node(pos).name].virtual_portstates
|
||||
if not vports then return {} end
|
||||
|
||||
-- Gather variables for the environment
|
||||
local vports_copy = {}
|
||||
for k, v in pairs(vports) do vports_copy[k] = v end
|
||||
local rports = get_real_port_states(pos)
|
||||
|
Loading…
Reference in New Issue
Block a user