Fixed a SIGSEGV bug at GUI initialization when CAT is enabled. The rig object was being called in on_bandComboBox_currentIndexChanged() before the rig object was instantiated.

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@3202 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
Edson W. R. Pereira 2013-04-23 19:16:50 +00:00
parent f8310a6fc1
commit 2318aaed30

View File

@ -199,7 +199,7 @@ MainWindow::MainWindow(QSharedMemory *shdmem, QWidget *parent) :
#endif
mem_jt9 = shdmem;
readSettings(); //Restore user's setup params
readSettings(); //Restore user's setup params
if(m_dFreq.length()<=1) {
m_dFreq.clear();
for(int i=0; i<16; i++) {
@ -517,6 +517,7 @@ void MainWindow::readSettings()
if(m_ndepth==1) ui->actionQuickDecode->setChecked(true);
if(m_ndepth==2) ui->actionMediumDecode->setChecked(true);
if(m_ndepth==3) ui->actionDeepestDecode->setChecked(true);
statusChanged();
}
@ -2439,6 +2440,9 @@ void MainWindow::on_bandComboBox_currentIndexChanged(int index)
m_repeatMsg=0;
m_secBandChanged=QDateTime::currentMSecsSinceEpoch()/1000;
if(m_catEnabled) {
if(!m_bRigOpen) {
rigOpen();
}
rig->setFreq(MHz(m_dialFreq));
}
}