projects
/
zefram
/
minetest
/
minetest_engine.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9056c16
)
Fix menu crash due to lack of favourites list
author
sapier
<Sapier at GMX dot net>
Sun, 22 Jun 2014 12:00:57 +0000
(14:00 +0200)
committer
sapier
<Sapier at GMX dot net>
Sun, 22 Jun 2014 12:00:57 +0000
(14:00 +0200)
builtin/mainmenu/tab_multiplayer.lua
patch
|
blob
|
history
diff --git
a/builtin/mainmenu/tab_multiplayer.lua
b/builtin/mainmenu/tab_multiplayer.lua
index d2d87274e74922570b7fbc97be19cf8ec7d75486..c3a7d921e2c7ced7e4d032e77f1dbb1555df0cae 100644
(file)
--- a/
builtin/mainmenu/tab_multiplayer.lua
+++ b/
builtin/mainmenu/tab_multiplayer.lua
@@
-138,6
+138,12
@@
local function main_button_handler(tabview, fields, name, tabdata)
else
fav_idx = 1
end
+
+ if menudata.favorites == nil or
+ menudata.favorites[fav_idx] == nil then
+ tabdata.fav_selected = 0
+ return true
+ end
local address = menudata.favorites[fav_idx].address
local port = menudata.favorites[fav_idx].port