1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-15 12:51:49 -05:00

ATV demod: fixed segfault when TV screen pointer is not set yet by the GUI

This commit is contained in:
f4exb 2018-03-30 23:41:48 +02:00
parent 2e89f7e5a9
commit deefab7c7c
2 changed files with 7 additions and 7 deletions

View File

@ -431,15 +431,15 @@ void ATVDemod::demod(Complex& c)
//********** process video sample **********
if (m_running.m_enmATVStandard == ATVStdHSkip)
if (m_registeredTVScreen) // can process only if the screen is available (set via the GUI)
{
if (m_running.m_enmATVStandard == ATVStdHSkip) {
processHSkip(fltVal, intVal);
}
else
{
} else {
processClassic(fltVal, intVal);
}
}
}
void ATVDemod::start()
{

View File

@ -231,7 +231,7 @@ public:
virtual QByteArray serialize() const { return QByteArray(); }
virtual bool deserialize(const QByteArray& data __attribute__((unused))) { return false; }
void setTVScreen(TVScreen *objScreen);
void setTVScreen(TVScreen *objScreen); //!< set by the GUI
int getSampleRate();
int getEffectiveSampleRate();
double getMagSq() const { return m_objMagSqAverage; } //!< Beware this is scaled to 2^30