diff options
author | Loic Blot <loic.blot@unix-experience.fr> | 2017-07-02 22:26:25 +0200 |
---|---|---|
committer | sfan5 <sfan5@live.de> | 2018-06-10 17:18:11 +0200 |
commit | 119aa5c91977ce5381e399e21eabf390e5cb5f5e (patch) | |
tree | ac314edfbb4c55c2e77a05f0950a2e3d002f0f75 | |
parent | fb4bfc60deeab6c54e9c51f7f7a0ccf595e42b77 (diff) | |
download | minetest-119aa5c91977ce5381e399e21eabf390e5cb5f5e.tar.gz minetest-119aa5c91977ce5381e399e21eabf390e5cb5f5e.tar.bz2 minetest-119aa5c91977ce5381e399e21eabf390e5cb5f5e.zip |
Fix crash due to missing pointer validation
Based on commit 014a1a0
-rw-r--r-- | src/game.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/game.cpp b/src/game.cpp index facc68aea..5ad93b95a 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -170,7 +170,8 @@ struct LocalFormspecHandler : public TextDest } // Don't disable this part when modding is disabled, it's used in builtin - m_client->getScript()->on_formspec_input(m_formname, fields); + if (m_client && m_client->getScript()) + m_client->getScript()->on_formspec_input(m_formname, fields); } Client *m_client; |