mirror of
https://gitlab.com/GaryOderNichts/re3-wiiu.git
synced 2024-11-29 04:24:14 +01:00
Fix map texture leak
This commit is contained in:
parent
4819d195d8
commit
a923728877
@ -3653,7 +3653,9 @@ CMenuManager::LoadAllTextures()
|
|||||||
#ifdef MENU_MAP
|
#ifdef MENU_MAP
|
||||||
static bool menuOptionAdded = false;
|
static bool menuOptionAdded = false;
|
||||||
for (int i = 0; i < ARRAY_SIZE(MapFilenames); i++) {
|
for (int i = 0; i < ARRAY_SIZE(MapFilenames); i++) {
|
||||||
if (!menuOptionAdded && RwTextureRead(MapFilenames[i][0], MapFilenames[i][1])) {
|
RwTexture *firstTile;
|
||||||
|
if (!menuOptionAdded && (firstTile = RwTextureRead(MapFilenames[i][0], MapFilenames[i][1]))) {
|
||||||
|
RwTextureDestroy(firstTile);
|
||||||
FrontendOptionSetCursor(MENUPAGE_PAUSE_MENU, 2, false);
|
FrontendOptionSetCursor(MENUPAGE_PAUSE_MENU, 2, false);
|
||||||
FrontendOptionAddBuiltinAction("FEG_MAP", MENUACTION_CHANGEMENU, MENUPAGE_MAP, SAVESLOT_NONE);
|
FrontendOptionAddBuiltinAction("FEG_MAP", MENUACTION_CHANGEMENU, MENUPAGE_MAP, SAVESLOT_NONE);
|
||||||
menuOptionAdded = true;
|
menuOptionAdded = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user