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

Unified Diff: content/browser/renderer_host/context_provider_factory_impl_android.cc

Issue 2233023003: content: Don't keep requesting the GpuChannelHost during shutdown. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: timer stop Created 4 years, 4 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 | « content/browser/gpu/browser_gpu_channel_host_factory.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/context_provider_factory_impl_android.cc
diff --git a/content/browser/renderer_host/context_provider_factory_impl_android.cc b/content/browser/renderer_host/context_provider_factory_impl_android.cc
index d3db9665c284e13e36f55d4cc0367b09b118cf8f..40cc97c1a4a271837d53117c4d92b6822012aae8 100644
--- a/content/browser/renderer_host/context_provider_factory_impl_android.cc
+++ b/content/browser/renderer_host/context_provider_factory_impl_android.cc
@@ -235,6 +235,11 @@ void ContextProviderFactoryImpl::OnGpuChannelEstablished(
scoped_refptr<gpu::GpuChannelHost> gpu_channel) {
establish_gpu_channel_timeout_.Stop();
+ // This should happen only during shutdown. So early out instead of queuing
+ // more requests with the factory.
+ if (!gpu_channel)
+ return;
+
// We can queue the Gpu Channel initialization requests multiple times as
// we get context requests. So we might have already handled any pending
// requests when this callback runs.
« no previous file with comments | « content/browser/gpu/browser_gpu_channel_host_factory.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698