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

Unified Diff: content/renderer/render_thread_impl.cc

Issue 8769018: Call WebCompositor::shutdown only when we have called WebCompositor::initialize (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 9 years, 1 month 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/renderer/render_thread_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_thread_impl.cc
diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc
index 6b9933a730fd22cc4c6eafaeb944969f4da90434..7fdb883a31dafaddd8e325a6200ce24dc30e6226 100644
--- a/content/renderer/render_thread_impl.cc
+++ b/content/renderer/render_thread_impl.cc
@@ -193,6 +193,7 @@ void RenderThreadImpl::Init() {
hidden_widget_count_ = 0;
idle_notification_delay_in_ms_ = kInitialIdleHandlerDelayMs;
idle_notifications_to_skip_ = 0;
+ compositor_initialized_ = false;
task_factory_.reset(new ScopedRunnableMethodFactory<RenderThreadImpl>(this));
appcache_dispatcher_.reset(new AppCacheDispatcher(Get()));
@@ -246,7 +247,10 @@ RenderThreadImpl::~RenderThreadImpl() {
file_thread_->Stop();
#ifdef WEBCOMPOSITOR_HAS_INITIALIZE
- WebKit::WebCompositor::shutdown();
+ if (compositor_initialized_) {
+ WebKit::WebCompositor::shutdown();
+ compositor_initialized_ = false;
+ }
#endif
if (compositor_thread_.get()) {
RemoveFilter(compositor_thread_->GetMessageFilter());
@@ -446,6 +450,7 @@ void RenderThreadImpl::EnsureWebKitInitialized() {
WebKit::WebCompositor::initialize(NULL);
#endif
}
+ compositor_initialized_ = true;
WebScriptController::enableV8SingleThreadMode();
« no previous file with comments | « content/renderer/render_thread_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698