1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-29 11:18:56 -05:00

NFM mod: fixed deserializer

This commit is contained in:
f4exb 2017-12-28 03:29:26 +01:00
parent 8399baeb4e
commit fa1e772383

View File

@ -474,19 +474,22 @@ QByteArray NFMMod::serialize() const
bool NFMMod::deserialize(const QByteArray& data)
{
if (m_settings.deserialize(data))
{
MsgConfigureNFMMod *msg = MsgConfigureNFMMod::create(m_settings, true);
m_inputMessageQueue.push(msg);
return true;
}
else
bool success = true;
if (!m_settings.deserialize(data))
{
m_settings.resetToDefaults();
success = false;
}
MsgConfigureChannelizer *msgChan = MsgConfigureChannelizer::create(
48000, m_settings.m_inputFrequencyOffset);
m_inputMessageQueue.push(msgChan);
MsgConfigureNFMMod *msg = MsgConfigureNFMMod::create(m_settings, true);
m_inputMessageQueue.push(msg);
return false;
}
return success;
}
int NFMMod::webapiSettingsGet(