diff --git a/ISLE/isleapp.cpp b/ISLE/isleapp.cpp index be89b97b..1b1af42a 100644 --- a/ISLE/isleapp.cpp +++ b/ISLE/isleapp.cpp @@ -1207,10 +1207,11 @@ bool IsleApp::LoadConfig() iniparser_freedict(dict); - if constexpr (std::is_same_v) { - SDL_free(prefPath); - } - + [](auto path) { + if constexpr (std::is_same_v) { + SDL_free(path); + } + }(prefPath); return true; }