From 6c42ebfafa7bc5762fe7ad64b4b9087ba1bc3c38 Mon Sep 17 00:00:00 2001 From: ChimneySwift Date: Sat, 10 Nov 2018 23:46:51 +1000 Subject: [PATCH] Escape special characters when searching the server list (#7842) Simple fix to stop searching for "[" or other special characters causing a crash. --- builtin/mainmenu/tab_online.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/builtin/mainmenu/tab_online.lua b/builtin/mainmenu/tab_online.lua index 8e88a7743..a057d0973 100644 --- a/builtin/mainmenu/tab_online.lua +++ b/builtin/mainmenu/tab_online.lua @@ -256,6 +256,7 @@ local function main_button_handler(tabview, fields, name, tabdata) -- setup the keyword list local keywords = {} for word in input:gmatch("%S+") do + word = word:gsub("(%W)", "%%%1") table.insert(keywords, word) end -- 2.25.1