Bug 1290747 - Fix bad assert in RasterImage::NotifyProgress(). r=edwin, a=ritu
authorSeth Fowler <mark.seth.fowler@gmail.com>
Sun, 31 Jul 2016 14:35:37 -0700
changeset 349649 587904a10d9a4f2934a5cff85c9415ad2fb5cb56
parent 349648 cc6d15ffcabec35355b7c3d56b7d147ab8fb448b
child 349650 291a9823eb6a705207b738ddb79b7b86bddc4db8
push id1230
push userjlund@mozilla.com
push dateMon, 31 Oct 2016 18:13:35 +0000
treeherdermozilla-release@5e06e3766db2 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersedwin, ritu
bugs1290747
milestone50.0a2
Bug 1290747 - Fix bad assert in RasterImage::NotifyProgress(). r=edwin, a=ritu
image/RasterImage.cpp
--- a/image/RasterImage.cpp
+++ b/image/RasterImage.cpp
@@ -1635,17 +1635,17 @@ RasterImage::NotifyProgress(Progress aPr
   const bool wasDefaultFlags = aSurfaceFlags == DefaultSurfaceFlags();
 
   if (!aInvalidRect.IsEmpty() && wasDefaultFlags) {
     // Update our image container since we're invalidating.
     UpdateImageContainer();
   }
 
   // We may have decoded new animation frames; update our animation state.
-  MOZ_ASSERT_IF(aFrameCount && *aFrameCount > 1, mAnimationState);
+  MOZ_ASSERT_IF(aFrameCount && *aFrameCount > 1, mAnimationState || mError);
   if (mAnimationState && aFrameCount) {
     mAnimationState->UpdateKnownFrameCount(*aFrameCount);
   }
 
   // If we should start animating right now, do so.
   if (mAnimationState && aFrameCount == Some(1u) &&
       mPendingAnimation && ShouldAnimate()) {
     StartAnimation();