diff options
author | Mike Klein <mtklein@chromium.org> | 2017-05-18 11:26:53 -0400 |
---|---|---|
committer | Mike Klein <mtklein@chromium.org> | 2017-05-18 15:50:39 +0000 |
commit | d06126a8185e2ace61bbb94edc7ff3bb9909803c (patch) | |
tree | d7937f7792c656bd35ce567365058350accf306a /src/core/SkRecords.cpp | |
parent | cfeaab807c8b2f33046949ed85cb1e833adbc3c7 (diff) |
Pre-cache SkPath's genID in PreCachedPath too
SkPath::getGenerationID() calls SkPathRef's, which is where the race is.
Change-Id: I71296b32148c8cda2d2b2fe249ef6b9ef84fcfe0
Reviewed-on: https://skia-review.googlesource.com/17316
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Diffstat (limited to 'src/core/SkRecords.cpp')
-rw-r--r-- | src/core/SkRecords.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/core/SkRecords.cpp b/src/core/SkRecords.cpp index 81dd92f9ef..e4b908692f 100644 --- a/src/core/SkRecords.cpp +++ b/src/core/SkRecords.cpp @@ -11,6 +11,7 @@ namespace SkRecords { PreCachedPath::PreCachedPath(const SkPath& path) : SkPath(path) { this->updateBoundsCache(); + (void)this->getGenerationID(); #if 0 // Disabled to see if we ever really race on this. It costs time, chromium:496982. SkPathPriv::FirstDirection junk; (void)SkPathPriv::CheapComputeFirstDirection(*this, &junk); |