Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(863)

Unified Diff: media/base/pipeline_impl.cc

Issue 2355173002: Clear pending reads after suspend completes, not before. (Closed)
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/pipeline_impl.cc
diff --git a/media/base/pipeline_impl.cc b/media/base/pipeline_impl.cc
index 0590d00cc550f21be7bc6842bbac941a4d516cde..7eb522b67b73106d8f09fb1da642307d4fa1fcfd 100644
--- a/media/base/pipeline_impl.cc
+++ b/media/base/pipeline_impl.cc
@@ -363,9 +363,6 @@ void PipelineImpl::RendererWrapper::Suspend() {
DCHECK(shared_state_.suspend_timestamp != kNoTimestamp);
}
- // Abort any reads the renderer may be blocked on.
- demuxer_->AbortPendingReads();
-
// Queue the asynchronous actions required to stop playback.
SerialRunner::Queue fns;
@@ -802,6 +799,9 @@ void PipelineImpl::RendererWrapper::CompleteSuspend(PipelineStatus status) {
shared_state_.statistics.video_memory_usage = 0;
}
+ // Abort any reads the renderer may have kicked off.
+ demuxer_->AbortPendingReads();
+
SetState(kSuspended);
main_task_runner_->PostTask(
FROM_HERE, base::Bind(&PipelineImpl::OnSuspendDone, weak_pipeline_));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698