Bug 1143575. ImageClient::UpdateImage should not return false when there's no image, because recreating the ImageClient won't help. r=nical draft
authorRobert O'Callahan <robert@ocallahan.org>
Thu, 19 Mar 2015 21:06:27 +1300
changeset 275587 1ee043469e2ce3f516919afdf4fa06fc90ee1800
parent 275586 b2be8062ca8a331e4a09d04a714d64018b8dee2f
child 275588 71a19d03549151272b36e4a3e33eb10272d23646
push id3189
push userrocallahan@mozilla.com
push dateFri, 03 Jul 2015 11:12:01 +0000
reviewersnical
bugs1143575
milestone42.0a1
Bug 1143575. ImageClient::UpdateImage should not return false when there's no image, because recreating the ImageClient won't help. r=nical
gfx/layers/client/ImageClient.cpp
--- a/gfx/layers/client/ImageClient.cpp
+++ b/gfx/layers/client/ImageClient.cpp
@@ -143,20 +143,16 @@ ImageClientSingle::UpdateImage(ImageCont
   uint32_t generationCounter;
   aContainer->GetCurrentImages(&images, &generationCounter);
 
   if (mLastUpdateGenerationCounter == generationCounter) {
     return true;
   }
   mLastUpdateGenerationCounter = generationCounter;
 
-  if (images.IsEmpty()) {
-    return false;
-  }
-
   Image* image = images[0].mImage;
   // Don't try to update to an invalid image. We return true because the caller
   // would attempt to recreate the ImageClient otherwise, and that isn't going
   // to help.
   if (!image->IsValid()) {
     return true;
   }