Simplify CThreadedReader to avoid race conditions

refs #731
This commit is contained in:
Roland Winklmeier
2016-08-11 23:18:51 +02:00
committed by Mathew Sutcliffe
parent 6b0412d68d
commit 4733c72553
9 changed files with 86 additions and 130 deletions

View File

@@ -48,7 +48,7 @@ namespace BlackCore
//! \name BlackCore::CThreadedReader overrides
//! @{
virtual void cleanup() override;
virtual BlackCore::Vatsim::CReaderSettings getSettings() const override;
virtual void doWorkImpl() override;
//! @}
private slots:
@@ -60,7 +60,9 @@ namespace BlackCore
void ps_read();
private:
BlackMisc::CSettingReadOnly<BlackCore::Vatsim::TVatsimBookings> m_settings { this };
void reloadSettings();
BlackMisc::CSettingReadOnly<BlackCore::Vatsim::TVatsimBookings> m_settings { this, &CVatsimBookingReader::reloadSettings };
};
} // ns
} // ns