From 7f7ec206de39fde8dc490e9feb0f65322af1b989 Mon Sep 17 00:00:00 2001 From: msarett Date: Tue, 1 Mar 2016 12:12:27 -0800 Subject: Fix bug in SkGifCodec / Switch SkImageDec tests to use Codec SkImageDecoder is still used throughout tests, tools, gms etc. Deleting it from tests is an easy first step. Bonus is that we add tests of SkCodec. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1733863003 Review URL: https://codereview.chromium.org/1733863003 --- tests/IndexedPngOverflowTest.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'tests/IndexedPngOverflowTest.cpp') diff --git a/tests/IndexedPngOverflowTest.cpp b/tests/IndexedPngOverflowTest.cpp index 78f8d94b1a..f516898a1a 100644 --- a/tests/IndexedPngOverflowTest.cpp +++ b/tests/IndexedPngOverflowTest.cpp @@ -5,10 +5,9 @@ * found in the LICENSE file. */ +#include "CodecPriv.h" #include "SkBitmap.h" #include "SkCanvas.h" -#include "SkForceLinking.h" -#include "SkImageDecoder.h" #include "SkImageInfo.h" #include "SkSurface.h" #include "Test.h" @@ -31,10 +30,7 @@ unsigned char gPng[] = { DEF_TEST(IndexedPngOverflow, reporter) { SkBitmap image; - SkForceLinking(false); - bool success = SkImageDecoder::DecodeMemory( - gPng, sizeof(gPng), &image, SkColorType::kUnknown_SkColorType, - SkImageDecoder::kDecodePixels_Mode); + bool success = decode_memory(gPng, sizeof(gPng), &image); REPORTER_ASSERT(reporter, success); SkAutoTUnref surface(SkSurface::NewRaster(SkImageInfo::MakeN32Premul(20, 1))); -- cgit v1.2.3