aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/android/SkBitmapRegionDecoder.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/android/SkBitmapRegionDecoder.cpp')
-rw-r--r--src/android/SkBitmapRegionDecoder.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/android/SkBitmapRegionDecoder.cpp b/src/android/SkBitmapRegionDecoder.cpp
index 8298fb5298..a6e3ac6d94 100644
--- a/src/android/SkBitmapRegionDecoder.cpp
+++ b/src/android/SkBitmapRegionDecoder.cpp
@@ -22,11 +22,10 @@ SkBitmapRegionDecoder* SkBitmapRegionDecoder::Create(
std::unique_ptr<SkStreamRewindable> streamDeleter(stream);
switch (strategy) {
case kAndroidCodec_Strategy: {
- std::unique_ptr<SkAndroidCodec> codec(
- SkAndroidCodec::NewFromStream(streamDeleter.release()));
+ auto codec = SkAndroidCodec::MakeFromStream(std::move(streamDeleter));
if (nullptr == codec) {
SkCodecPrintf("Error: Failed to create codec.\n");
- return NULL;
+ return nullptr;
}
switch ((SkEncodedImageFormat)codec->getEncodedFormat()) {