lcd4linux.cpp: avoid possible crash if getLiveFE() returns NULL

Watched with generic build for pc without tuner hardware.
This commit is contained in:
2021-06-15 18:42:28 +02:00
parent 4592cbc239
commit 692e9c3b9b

View File

@@ -533,6 +533,8 @@ void CLCD4l::ParseInfo(uint64_t parseID, bool newID, bool firstRun)
/* ----------------------------------------------------------------- */ /* ----------------------------------------------------------------- */
if (CFEManager::getInstance()->getLiveFE())
{
int Tuner = 1 + CFEManager::getInstance()->getLiveFE()->getNumber(); int Tuner = 1 + CFEManager::getInstance()->getLiveFE()->getNumber();
if (m_Tuner != Tuner) if (m_Tuner != Tuner)
@@ -540,7 +542,7 @@ void CLCD4l::ParseInfo(uint64_t parseID, bool newID, bool firstRun)
WriteFile(TUNER, to_string(Tuner)); WriteFile(TUNER, to_string(Tuner));
m_Tuner = Tuner; m_Tuner = Tuner;
} }
}
/* ----------------------------------------------------------------- */ /* ----------------------------------------------------------------- */
int Volume = g_settings.current_volume; int Volume = g_settings.current_volume;