diff options
| author | 2015-11-10 23:31:11 +0000 | |
|---|---|---|
| committer | 2015-11-10 23:31:11 +0000 | |
| commit | 1b85ce17a316973a170b3932f2d0a9b02063eaa3 (patch) | |
| tree | 7491f4e974e7acb57205781b31d29e045fdc4d19 /libs/hwui/PathCache.cpp | |
| parent | 16009a6deaff272c94046facbeb567bafdaacc69 (diff) | |
| parent | 7516d4d8667957688433b02b2f4985f1b3ab36ad (diff) | |
Merge "Fix HWUI Path Cache dangling pointer" am: 37bf3ec9d2
am: 7516d4d866
* commit '7516d4d8667957688433b02b2f4985f1b3ab36ad':
Fix HWUI Path Cache dangling pointer
Diffstat (limited to 'libs/hwui/PathCache.cpp')
| -rw-r--r-- | libs/hwui/PathCache.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/libs/hwui/PathCache.cpp b/libs/hwui/PathCache.cpp index 3af640f76365..3236f6f7c24d 100644 --- a/libs/hwui/PathCache.cpp +++ b/libs/hwui/PathCache.cpp @@ -400,6 +400,13 @@ PathTexture* PathCache::get(const SkPath* path, const SkPaint* paint) { return texture; } +void PathCache::remove(const SkPath* path, const SkPaint* paint) +{ + PathDescription entry(kShapePath, paint); + entry.shape.path.mGenerationID = path->getGenerationID(); + mCache.remove(entry); +} + void PathCache::precache(const SkPath* path, const SkPaint* paint) { if (!Caches::getInstance().tasks.canRunTasks()) { return; |