cabana: fix core dump when failed to connect to panda (#28529)

This commit is contained in:
Dean Lee
2023-06-14 01:49:59 +08:00
committed by GitHub
parent e54d05b42f
commit 7128daebba
+6 -1
View File
@@ -42,7 +42,12 @@ int main(int argc, char *argv[]) {
if (cmd_parser.isSet("panda-serial")) {
config.serial = cmd_parser.value("panda-serial");
}
stream = new PandaStream(&app, config);
try {
stream = new PandaStream(&app, config);
} catch (std::exception &e) {
qWarning() << e.what();
return 0;
}
} else {
uint32_t replay_flags = REPLAY_FLAG_NONE;
if (cmd_parser.isSet("ecam")) {