mirror of
https://github.com/minetest/minetest.git
synced 2024-11-12 18:53:46 +01:00
Fix client crash on when con::PeerNotFoundException is thrown (#11286)
This commit is contained in:
parent
93f43c890b
commit
673c29f7ea
@ -277,14 +277,6 @@ bool ClientLauncher::run(GameStartData &start_data, const Settings &cmd_args)
|
|||||||
chat_backend,
|
chat_backend,
|
||||||
&reconnect_requested
|
&reconnect_requested
|
||||||
);
|
);
|
||||||
m_rendering_engine->get_scene_manager()->clear();
|
|
||||||
|
|
||||||
#ifdef HAVE_TOUCHSCREENGUI
|
|
||||||
delete g_touchscreengui;
|
|
||||||
g_touchscreengui = NULL;
|
|
||||||
receiver->m_touchscreengui = NULL;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} //try
|
} //try
|
||||||
catch (con::PeerNotFoundException &e) {
|
catch (con::PeerNotFoundException &e) {
|
||||||
error_message = gettext("Connection error (timed out?)");
|
error_message = gettext("Connection error (timed out?)");
|
||||||
@ -300,6 +292,14 @@ bool ClientLauncher::run(GameStartData &start_data, const Settings &cmd_args)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
m_rendering_engine->get_scene_manager()->clear();
|
||||||
|
|
||||||
|
#ifdef HAVE_TOUCHSCREENGUI
|
||||||
|
delete g_touchscreengui;
|
||||||
|
g_touchscreengui = NULL;
|
||||||
|
receiver->m_touchscreengui = NULL;
|
||||||
|
#endif
|
||||||
|
|
||||||
// If no main menu, show error and exit
|
// If no main menu, show error and exit
|
||||||
if (skip_main_menu) {
|
if (skip_main_menu) {
|
||||||
if (!error_message.empty()) {
|
if (!error_message.empty()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user