Reference ctable when adopting pointer in Bitmap

Change-Id: I56aea10928f0ec73756ed055488a3e3516a9096e
Test: manual.
bug:32621254, 32561595
This commit is contained in:
sergeyv
2016-11-03 10:00:32 -07:00
parent 3c17728297
commit 003f142562

View File

@@ -307,7 +307,7 @@ void Bitmap::reconfigure(const SkImageInfo& newInfo, size_t rowBytes, SkColorTab
}
mRowBytes = rowBytes;
if (mColorTable.get() != ctable) {
mColorTable.reset(ctable);
mColorTable.reset(SkSafeRef(ctable));
}
// Need to validate the alpha type to filter against the color type