diff --git a/Common/Log/LogManager.cpp b/Common/Log/LogManager.cpp index 38f4745bd7..f44e2c6ce0 100644 --- a/Common/Log/LogManager.cpp +++ b/Common/Log/LogManager.cpp @@ -149,15 +149,6 @@ void LogManager::Shutdown() { ringLog_.Clear(); initialized_ = false; - - for (size_t i = 0; i < ARRAY_SIZE(g_log); i++) { - g_log[i].enabled = true; -#if defined(_DEBUG) - g_log[i].level = LogLevel::LDEBUG; -#else - g_log[i].level = LogLevel::LINFO; -#endif - } } LogManager::LogManager() { diff --git a/Common/UI/Screen.cpp b/Common/UI/Screen.cpp index c28974828b..20ee69b01d 100644 --- a/Common/UI/Screen.cpp +++ b/Common/UI/Screen.cpp @@ -42,6 +42,10 @@ ScreenManager::~ScreenManager() { } void ScreenManager::switchScreen(Screen *screen) { + if (!screen) { + ERROR_LOG(Log::UI, "Can't switch to empty screen"); + return; + } // TODO: inputLock_ ? INFO_LOG(Log::UI, "ScreenManager::switchScreen('%s')", screen->tag());