diff --git a/src/zm_monitor.cpp b/src/zm_monitor.cpp index 4f52ad34ff..f14ab8fa0d 100644 --- a/src/zm_monitor.cpp +++ b/src/zm_monitor.cpp @@ -3396,6 +3396,7 @@ int Monitor::Pause() { sws_freeContext(convert_context); convert_context = nullptr; } + decoding_image_count = 0; } if (analysis_thread) { Debug(1, "Joining analysis"); diff --git a/src/zm_monitor.h b/src/zm_monitor.h index aa7c0c2a91..9a62ebfa7d 100644 --- a/src/zm_monitor.h +++ b/src/zm_monitor.h @@ -741,7 +741,7 @@ class Monitor : public std::enable_shared_from_this { return false; } if (decoding_image_count >= ready_count) { - Debug(4, "Ready because image_count(%d) >= ready_count(%d)", decoding_image_count, ready_count); + Debug(4, "Ready because decoding_image_count(%d) >= ready_count(%d)", decoding_image_count, ready_count); return true; } Debug(4, "Not ready because decoding_image_count(%d) <= ready_count(%d)", decoding_image_count, ready_count);