Bug 1124610 - Call PostHasTransparency for corrupt images that we treat as usable. r=jrmuizel, a=sledru
authorSeth Fowler <seth@mozilla.com>
Tue, 03 Feb 2015 02:36:33 -0800
changeset 243712 3347b3531c98
parent 243711 6f3775d5c839
child 243713 5a2b0dfc3832
push id4449
push userryanvm@gmail.com
push date2015-02-09 15:46 +0000
treeherdermozilla-beta@130e59d97b15 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjrmuizel, sledru
bugs1124610
milestone36.0
Bug 1124610 - Call PostHasTransparency for corrupt images that we treat as usable. r=jrmuizel, a=sledru
image/src/Decoder.cpp
--- a/image/src/Decoder.cpp
+++ b/image/src/Decoder.cpp
@@ -189,16 +189,19 @@ Decoder::Finish(ShutdownReason aReason)
       if (GetCompleteFrameCount() == 0) {
         usable = false;
       }
     }
 
     // If we're usable, do exactly what we should have when the decoder
     // completed.
     if (usable) {
+      // Not writing to the entire frame may have left us transparent.
+      PostHasTransparency();
+
       if (mInFrame) {
         PostFrameStop();
       }
       PostDecodeDone();
     } else {
       if (!IsSizeDecode()) {
         mProgress |= FLAG_DECODE_COMPLETE | FLAG_ONLOAD_UNBLOCKED;
       }