diff --git a/src/engines/gstengine.cpp b/src/engines/gstengine.cpp index 51798253d..7f903ff7b 100755 --- a/src/engines/gstengine.cpp +++ b/src/engines/gstengine.cpp @@ -317,6 +317,11 @@ void GstEngine::UpdateScope(int chunk_length) { memcpy(dest, source, bytes); gst_buffer_unmap(latest_buffer_, &map); + + if (scope_chunk_ == scope_chunks_) { + gst_buffer_unref(latest_buffer_); + latest_buffer_ = nullptr; + } } void GstEngine::StartPreloading(const QUrl& url, bool force_stop_at_end,