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

Unified Diff: content/renderer/gpu/compositor_output_surface.cc

Issue 11044008: Dont let messages hit CompositorOutputSurface after it is destroyed. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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/renderer/gpu/compositor_output_surface.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/gpu/compositor_output_surface.cc
diff --git a/content/renderer/gpu/compositor_output_surface.cc b/content/renderer/gpu/compositor_output_surface.cc
index f0704ffb7c6cf2457fec02bd4771a01fa66f6a18..e50a1e93aa420458328ac9fa3628bb0006a3db65 100644
--- a/content/renderer/gpu/compositor_output_surface.cc
+++ b/content/renderer/gpu/compositor_output_surface.cc
@@ -46,6 +46,7 @@ CompositorOutputSurface::~CompositorOutputSurface() {
DCHECK(CalledOnValidThread());
if (!client_)
return;
+ output_surface_proxy_->ClearOutputSurface();
output_surface_filter_->RemoveRoute(routing_id_);
}
@@ -66,10 +67,11 @@ bool CompositorOutputSurface::bindToClient(
client_ = client;
+ output_surface_proxy_ = new CompositorOutputSurfaceProxy(this);
output_surface_filter_->AddRoute(
routing_id_,
- base::Bind(&CompositorOutputSurface::OnMessageReceived,
- base::Unretained(this)));
+ base::Bind(&CompositorOutputSurfaceProxy::OnMessageReceived,
+ output_surface_proxy_));
return true;
}
« no previous file with comments | « content/renderer/gpu/compositor_output_surface.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698