Allow threads to reopen after closing

This commit is contained in:
Paul Hollinsky
2018-11-16 17:08:53 -05:00
parent 0cf1e7fe7f
commit 07a5dc4118
7 changed files with 14 additions and 1 deletions
@@ -12,8 +12,10 @@ void MultiChannelCommunication::spawnThreads() {
}
void MultiChannelCommunication::joinThreads() {
closing = true;
if(mainChannelReadThread.joinable())
mainChannelReadThread.join();
closing = false;
}
bool MultiChannelCommunication::sendPacket(std::vector<uint8_t>& bytes) {