From 8e34b5fbd32766682e3c140f3a71e7ca37ffd909 Mon Sep 17 00:00:00 2001 From: flb Date: Wed, 8 Sep 2021 12:14:21 +0200 Subject: [PATCH] Fixed exclude page crashing (closes https://github.com/HamletDuFromage/aio-switch-updater/issues/135) --- .gitignore | 1 + source/app_page.cpp | 6 ++---- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 6b3b103..0557c37 100644 --- a/.gitignore +++ b/.gitignore @@ -11,6 +11,7 @@ switch/ *.bin *.nsp *.psd +*.bak resources/i18n/zh-Hans resources/i18n/zh-Hant resources/i18n/en-GB diff --git a/source/app_page.cpp b/source/app_page.cpp index f8a1819..b9110d6 100644 --- a/source/app_page.cpp +++ b/source/app_page.cpp @@ -235,16 +235,15 @@ void AppPage_Exclude::PopulatePage() listItem->setThumbnail(controlData->icon, sizeof(controlData->icon)); items.insert(std::make_pair(listItem, util::formatApplicationId(tid))); list->addView(listItem); - - free(controlData); } - delete[] records; + free(controlData); } } else { label = new brls::Label(brls::LabelStyle::SMALL, "menus/common/applet_mode_not_supported"_i18n, true); list->addView(label); } + delete[] records; list->registerAction("menus/cheats/exclude_titles_save"_i18n, brls::Key::B, [this] { std::set exclude; @@ -298,4 +297,3 @@ void AppPage_DownloadedCheats::GetExistingCheatsTids() { } } } -