Remove thread pointer checking.

This commit is contained in:
Jared Boone 2016-06-24 15:46:53 -07:00
parent f8a473d56b
commit 9188bb9ee9
2 changed files with 6 additions and 10 deletions

View File

@ -58,11 +58,9 @@ BasebandThread::BasebandThread(const tprio_t priority) {
} }
BasebandThread::~BasebandThread() { BasebandThread::~BasebandThread() {
if( thread ) { chThdTerminate(thread);
chThdTerminate(thread); chThdWait(thread);
chThdWait(thread); thread = nullptr;
thread = nullptr;
}
} }
void BasebandThread::set_configuration(const BasebandConfiguration& new_configuration) { void BasebandThread::set_configuration(const BasebandConfiguration& new_configuration) {

View File

@ -40,11 +40,9 @@ RSSIThread::RSSIThread(const tprio_t priority) {
} }
RSSIThread::~RSSIThread() { RSSIThread::~RSSIThread() {
if( thread ) { chThdTerminate(thread);
chThdTerminate(thread); chThdWait(thread);
chThdWait(thread); thread = nullptr;
thread = nullptr;
}
} }
void RSSIThread::run() { void RSSIThread::run() {