Bug 1127405 - Remove the ForceRemove in CanvasClientSharedSurface to prevent crash. r=nical, a=sledru
authorEthan Lin <etlin@mozilla.com>
Tue, 03 Feb 2015 18:15:00 +0100
changeset 249634 bc1eddfe7e5311130c022f7cfae4dbd4760780cf
parent 249633 0cb3b566de1bd451bda399889c5791e6dfcaf169
child 249635 4809687351b318444a8dac821a6b0887309bd615
push id4489
push userraliiev@mozilla.com
push dateMon, 23 Feb 2015 15:17:55 +0000
treeherdermozilla-beta@fd7c3dc24146 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnical, sledru
bugs1127405
milestone37.0a2
Bug 1127405 - Remove the ForceRemove in CanvasClientSharedSurface to prevent crash. r=nical, a=sledru
gfx/layers/client/CanvasClient.cpp
--- a/gfx/layers/client/CanvasClient.cpp
+++ b/gfx/layers/client/CanvasClient.cpp
@@ -401,22 +401,16 @@ CanvasClientSharedSurface::Update(gfx::I
 
   forwarder->UpdatedTexture(this, mFrontTex, nullptr);
   forwarder->UseTexture(this, mFrontTex);
 }
 
 void
 CanvasClientSharedSurface::ClearSurfaces()
 {
-  if (mFrontTex && (mFront || mPrevFront)) {
-    // Force a synchronous destruction so that the TextureHost does not
-    // outlive the SharedSurface. This won't be needed once TextureClient/Host
-    // and SharedSurface are merged.
-    mFrontTex->ForceRemove(true /* sync */);
-    mFrontTex = nullptr;
-  }
+  mFrontTex = nullptr;
   // It is important to destroy the SharedSurface *after* the TextureClient.
   mFront = nullptr;
   mPrevFront = nullptr;
 }
 
 }
 }