Bug 1124907 - Call SetCompositor() only when it is valid r=nical
authorSotaro Ikeda <sikeda@mozilla.com>
Tue, 24 Mar 2015 07:21:15 -0700
changeset 264191 331ed8230be21fcd9ea0064eebf2b8df0cf8ba2c
parent 264190 f6850a11e3158d4235a538b609ac19b0b7b57287
child 264192 50d681158e9f4636dabc3c6f525d7604654b6e72
push id4718
push userraliiev@mozilla.com
push dateMon, 11 May 2015 18:39:53 +0000
treeherdermozilla-beta@c20c4ef55f08 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnical
bugs1124907
milestone39.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1124907 - Call SetCompositor() only when it is valid r=nical
gfx/layers/composite/CompositableHost.cpp
--- a/gfx/layers/composite/CompositableHost.cpp
+++ b/gfx/layers/composite/CompositableHost.cpp
@@ -104,17 +104,19 @@ CompositableHost::FromIPDLActor(PComposi
 }
 
 void
 CompositableHost::UseTextureHost(TextureHost* aTexture)
 {
   if (!aTexture) {
     return;
   }
-  aTexture->SetCompositor(GetCompositor());
+  if (GetCompositor()) {
+    aTexture->SetCompositor(GetCompositor());
+  }
 }
 
 void
 CompositableHost::UseComponentAlphaTextures(TextureHost* aTextureOnBlack,
                                             TextureHost* aTextureOnWhite)
 {
   MOZ_ASSERT(aTextureOnBlack && aTextureOnWhite);
   aTextureOnBlack->SetCompositor(GetCompositor());