| Index: src/core/SkPictureData.cpp
|
| diff --git a/src/core/SkPictureData.cpp b/src/core/SkPictureData.cpp
|
| index 9ed98cf4ff9e0ccc1f33c9760a1feab57312cda1..4391be4acf5d59d6ec06cf79d5e157ea5a13909e 100644
|
| --- a/src/core/SkPictureData.cpp
|
| +++ b/src/core/SkPictureData.cpp
|
| @@ -46,7 +46,13 @@ SkPictureData::SkPictureData(const SkPictureRecord& record,
|
|
|
| fBitmaps = record.fBitmaps;
|
| fPaints = record.fPaints;
|
| - fPaths = record.fPaths;
|
| +
|
| + fPaths.reset(record.fPaths.count());
|
| + record.fPaths.foreach([this](const SkPath& path, int n) {
|
| + // These indices are logically 1-based, but we need to serialize them
|
| + // 0-based to keep the deserializing SkPictureData::getPath() working.
|
| + fPaths[n-1] = path;
|
| + });
|
|
|
| this->initForPlayback();
|
|
|
|
|