Fix another heap-use-after-free in pause menu.
authorIlya Zhuravlev <zhuravlevilya@ya.ru>
Thu, 16 Jan 2014 12:54:50 +0000 (16:54 +0400)
committerkwolekr <kwolekr@minetest.net>
Wed, 5 Feb 2014 03:17:02 +0000 (22:17 -0500)
src/guiPauseMenu.cpp

index d7a51488ec54b1242c078bcc03dae7bde62aafea..4d5070c9be2528a2acc2188e1198572fbd0cdc9d 100644 (file)
@@ -256,12 +256,12 @@ bool GUIPauseMenu::OnEvent(const SEvent& event)
                                // ALWAYS return immediately after quitMenu()
                                return true;
                        case 261:
-                               quitMenu();
                                m_gamecallback->changePassword();
+                               quitMenu();
                                return true;
                        case 262:
-                               quitMenu();
                                m_gamecallback->changeVolume();
+                               quitMenu();
                                return true;
                        case 260: // disconnect
                                m_gamecallback->disconnect();