From cb8b1ea4ff6b677e28768ffae42881217ab79491 Mon Sep 17 00:00:00 2001 From: marco_a <4279489-marco_a@users.noreply.gitlab.com> Date: Mon, 18 Jan 2021 23:49:28 +0100 Subject: [PATCH] BGM formspec: sanitise title and author --- _editor/tools_bgm.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/_editor/tools_bgm.lua b/_editor/tools_bgm.lua index c09e16a..adf84f6 100644 --- a/_editor/tools_bgm.lua +++ b/_editor/tools_bgm.lua @@ -177,8 +177,8 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) return -- sennĂ² applico la traccia indicata else - local title = fields.title ~= "" and fields.title or nil - local author = fields.author ~= "" and fields.author or nil + local title = fields.title ~= "" and minetest.formspec_escape(fields.title) or nil + local author = fields.author ~= "" and minetest.formspec_escape(fields.author) or nil arena_lib.set_bgm(p_name, mod, arena_name, fields.bgm, title, author, calc_gain(fields.gain), calc_pitch(fields.pitch), true) end