[Scummvm-git-logs] scummvm master -> 2cbb611821f6cbc516da5ffc01812ba29a69450d
sev-
sev at scummvm.org
Sat Apr 4 14:25:17 UTC 2020
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
2cbb611821 GRAPHICS: MACGUI: Fix double freeing of menus
Commit: 2cbb611821f6cbc516da5ffc01812ba29a69450d
https://github.com/scummvm/scummvm/commit/2cbb611821f6cbc516da5ffc01812ba29a69450d
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-04-04T16:24:51+02:00
Commit Message:
GRAPHICS: MACGUI: Fix double freeing of menus
Changed paths:
graphics/macgui/macwindowmanager.cpp
diff --git a/graphics/macgui/macwindowmanager.cpp b/graphics/macgui/macwindowmanager.cpp
index db65bcd0a4..64d4a3779d 100644
--- a/graphics/macgui/macwindowmanager.cpp
+++ b/graphics/macgui/macwindowmanager.cpp
@@ -239,7 +239,10 @@ void MacWindowManager::addWindowInitialized(MacWindow *macwindow) {
}
MacMenu *MacWindowManager::addMenu() {
- delete _menu;
+ if (_menu) {
+ _windows[_menu->getId()] = nullptr;
+ delete _menu;
+ }
_menu = new MacMenu(getNextId(), _screen->getBounds(), this);
More information about the Scummvm-git-logs
mailing list