Bug 1101759 - Correctly record when we flush data during sync decodes. r=tn
authorSeth Fowler <seth@mozilla.com>
Thu, 20 Nov 2014 00:59:05 -0800
changeset 216617 faaa05e4e03d04eb9b9c868e984c9f1bcdd02991
parent 216616 c13daeb9246954765810a6e6698aa155611da5e6
child 216618 1aebb84c8af12888b9135b72716560c06d10c889
push idunknown
push userunknown
push dateunknown
reviewerstn
bugs1101759
milestone36.0a1
Bug 1101759 - Correctly record when we flush data during sync decodes. r=tn
image/src/Decoder.cpp
--- a/image/src/Decoder.cpp
+++ b/image/src/Decoder.cpp
@@ -132,16 +132,18 @@ Decoder::Write(const char* aBuffer, uint
   if (aStrategy == DecodeStrategy::SYNC) {
     while (NeedsNewFrame() && !HasDataError()) {
       nsresult rv = AllocateFrame();
 
       if (NS_SUCCEEDED(rv)) {
         // Use the data we saved when we asked for a new frame.
         WriteInternal(nullptr, 0, aStrategy);
       }
+
+      mNeedsToFlushData = false;
     }
   }
 
   // Finish telemetry.
   mDecodeTime += (TimeStamp::Now() - start);
 }
 
 void