Don't loop forever ignoring sigterm on initial connect

speed_ai^2
Isaac Connor 2025-01-16 17:29:10 -05:00
parent b5ee966d90
commit 8e5a9e462c
1 changed files with 3 additions and 1 deletions

View File

@ -246,10 +246,12 @@ int main(int argc, char *argv[]) {
monitor->LoadCamera();
while (!monitor->connect()) {
while (!monitor->connect() and !zm_terminate) {
Warning("Couldn't connect to monitor %d", monitor->Id());
sleep(1);
}
if (zm_terminate) break;
SystemTimePoint now = std::chrono::system_clock::now();
monitor->SetStartupTime(now);