| Index: gm/fontcache.cpp
|
| diff --git a/gm/fontcache.cpp b/gm/fontcache.cpp
|
| index c4af48930428fde367f21054b702ef3905537f7a..30f8892c78f88c1a93ae71deade77dc8d6f061b5 100644
|
| --- a/gm/fontcache.cpp
|
| +++ b/gm/fontcache.cpp
|
| @@ -20,7 +20,15 @@
|
|
|
| class FontCacheGM : public skiagm::GM {
|
| public:
|
| - FontCacheGM() {}
|
| + FontCacheGM() {
|
| + fTypefaces[0] = nullptr;
|
| + fTypefaces[1] = nullptr;
|
| + }
|
| +
|
| + virtual ~FontCacheGM() {
|
| + SkSafeUnref(fTypefaces[0]);
|
| + SkSafeUnref(fTypefaces[1]);
|
| + }
|
|
|
| protected:
|
| SkString onShortName() override {
|
| @@ -68,7 +76,7 @@
|
| }
|
|
|
| private:
|
| - sk_sp<SkTypeface> fTypefaces[2];
|
| + SkTypeface* fTypefaces[2];
|
| typedef GM INHERITED;
|
| };
|
|
|
|
|