mirror of
https://github.com/dragonpilot/dragonpilot.git
synced 2026-07-18 11:22:03 +08:00
boardd: fix segfault when SIGINT with no pandas (#22914)
* boardd: fix segfault when SIGINT with no pandas * remove if block Co-authored-by: Robbe Derks <robbe.derks@gmail.com>
This commit is contained in:
@@ -669,6 +669,11 @@ int main(int argc, char* argv[]) {
|
||||
}
|
||||
}
|
||||
|
||||
if (pandas.size() == 0) {
|
||||
// do_exit was set while not connected to a panda
|
||||
return 0;
|
||||
}
|
||||
|
||||
peripheral_panda = pandas[0];
|
||||
|
||||
LOGW("connected to board");
|
||||
|
||||
Reference in New Issue
Block a user