cabana: don't check for socketcan when not available (#34039)

This commit is contained in:
Patrick Bassut 2024-11-16 15:29:26 -03:00 committed by GitHub
parent 863d86c10c
commit 22d19f2fc4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -49,7 +49,7 @@ int main(int argc, char *argv[]) {
qWarning() << e.what();
return 0;
}
} else if (cmd_parser.isSet("socketcan")) {
} else if (SocketCanStream::available() && cmd_parser.isSet("socketcan")) {
stream = new SocketCanStream(&app, {.device = cmd_parser.value("socketcan")});
} else {
uint32_t replay_flags = REPLAY_FLAG_NONE;