Bug 1262338 (Part 2) - Use the WriteRows API correctly in RemoveFrameRectFilter::AdvanceRow(). r=njn
authorSeth Fowler <mark.seth.fowler@gmail.com>
Wed, 25 May 2016 22:48:29 -0700
changeset 299097 bea7a677b4191bb1bc5b017fdd73924c77f8b5ba
parent 299096 f5442ff12b331819dbcc1121053e68231763cb6c
child 299098 fc7ce4b5807cf02d6132e823439f3bc84904b2df
push id77429
push usermfowler@mozilla.com
push dateThu, 26 May 2016 05:49:04 +0000
treeherdermozilla-inbound@e13e5ddca69f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnjn
bugs1262338
milestone49.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 1262338 (Part 2) - Use the WriteRows API correctly in RemoveFrameRectFilter::AdvanceRow(). r=njn
image/SurfaceFilters.h
--- a/image/SurfaceFilters.h
+++ b/image/SurfaceFilters.h
@@ -510,21 +510,22 @@ protected:
 
     // If there's still more data coming, just adjust the pointer and return.
     if (mRow < mFrameRect.YMost() || rowPtr == nullptr) {
       return AdjustRowPointer(rowPtr);
     }
 
     // We've finished the region specified by the frame rect. Advance to the end
     // of the next pipeline stage's buffer, outputting blank rows.
-    mNext.template WriteRows<uint32_t>([&](uint32_t* aRow, uint32_t aLength) {
-      memset(rowPtr, 0, aLength * sizeof(uint32_t));
+    mNext.template WriteRows<uint32_t>([](uint32_t* aRow, uint32_t aLength) {
+      memset(aRow, 0, aLength * sizeof(uint32_t));
       return Nothing();
     });
 
+    mRow = InputSize().height;
     return nullptr;  // We're done.
   }
 
 private:
   uint8_t* AdjustRowPointer(uint8_t* aNextRowPointer) const
   {
     if (mBuffer) {
       MOZ_ASSERT(aNextRowPointer == mBuffer.get());