From fd489c2c8df45362d94a4990d9d89048478faeb8 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Sat, 1 Jan 2022 17:53:45 -0500 Subject: [PATCH] Fix. Need to use system_clock --- src/zm_monitor.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/zm_monitor.h b/src/zm_monitor.h index 443cd1318..9ad5c05ab 100644 --- a/src/zm_monitor.h +++ b/src/zm_monitor.h @@ -544,7 +544,12 @@ public: } bool hasViewers() { if (shared_data && shared_data->valid) { - TimePoint now = std::chrono::steady_clock::now(); + SystemTimePoint now = std::chrono::system_clock::now(); + Debug(1, "Last viewed %" PRId64 " seconds ago", + static_cast(std::chrono::duration_cast(now.time_since_epoch()).count()) + - + shared_data->last_viewed_time + ); return ( ( static_cast(std::chrono::duration_cast(now.time_since_epoch()).count())