Don't log errors when querying a monitor in NONE Function. Just report a 0 status.Fixes #3397

This commit is contained in:
Isaac Connor 2021-12-14 14:06:48 -05:00
parent f6d0274f74
commit 61fe35a32a
1 changed files with 10 additions and 0 deletions

View File

@ -497,6 +497,16 @@ int main(int argc, char *argv[]) {
if ( verbose ) {
printf("Monitor %u(%s)\n", monitor->Id(), monitor->Name());
}
if (monitor->GetFunction() == Monitor::NONE) {
if (verbose) {
printf("Current state: None\n");
} else {
printf("%d", Monitor::UNKNOWN);
}
exit_zmu(-1);
}
if ( !monitor->connect() ) {
Error("Can't connect to capture daemon: %d %s", monitor->Id(), monitor->Name());
exit_zmu(-1);