| Index: tests/CodecPartialTest.cpp
|
| diff --git a/tests/CodecPartialTest.cpp b/tests/CodecPartialTest.cpp
|
| index 22d4e7b594dec186e8543899a31c86cb0c7d5ae2..ff91c642e2d8bec0b71dc6ed91ec16e5fa219db9 100644
|
| --- a/tests/CodecPartialTest.cpp
|
| +++ b/tests/CodecPartialTest.cpp
|
| @@ -216,7 +216,15 @@ DEF_TEST(Codec_partialAnim, r) {
|
| // getFrameInfo lets us do this, since it tells the number of frames
|
| // not considering whether they are complete.
|
| // FIXME: Should we use a different Result?
|
| - if (fullCodec->getFrameInfo().size() > i) {
|
| + const size_t frameCount = [&fullCodec]() -> size_t {
|
| + std::vector<SkCodec::FrameInfo> frameInfos;
|
| + if (!fullCodec->getFrameInfo(&frameInfos, nullptr)) {
|
| + return 0;
|
| + }
|
| + return frameInfos.size();
|
| + }();
|
| +
|
| + if (frameCount > i) {
|
| // This is a partial frame.
|
| frames.push_back(frame);
|
| }
|
|
|