fixed pointer exception on disconnect

master
gregjhogan 2017-12-02 01:02:16 -06:00
parent 15bfed8d34
commit 35cc32a250
1 changed files with 1 additions and 1 deletions

View File

@ -112,7 +112,7 @@ DWORD PandaJ2534Device::can_recv_thread() {
}
} else {
for (auto& conn : this->connections)
if (conn->isProtoCan() && conn->getPort() == msg_in.bus)
if (conn != nullptr && conn->isProtoCan() && conn->getPort() == msg_in.bus)
conn->processMessage(msg_out);
}
}