Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(130)

Unified Diff: src/core/SkImageFilter.cpp

Issue 651723003: Require SK_DECLARE_STATIC_LAZY_PTR is used in global scope. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: safe unref Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/core/SkGlyphCache.cpp ('k') | src/core/SkLazyPtr.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkImageFilter.cpp
diff --git a/src/core/SkImageFilter.cpp b/src/core/SkImageFilter.cpp
index 6f7762ac466d68e010caedd3c7b97a350e3b71eb..c431ece9477b88a6a90e03c55002a0a933804319 100644
--- a/src/core/SkImageFilter.cpp
+++ b/src/core/SkImageFilter.cpp
@@ -97,7 +97,7 @@ bool SkImageFilter::Common::unflatten(SkReadBuffer& buffer, int expectedCount) {
if (!buffer.isValid() || !buffer.validate(SkIsValidRect(rect))) {
return false;
}
-
+
uint32_t flags = buffer.readUInt();
fCropRect = CropRect(rect, flags);
if (buffer.isVersionLT(SkReadBuffer::kImageFilterUniqueID_Version)) {
@@ -495,7 +495,8 @@ SkImageFilter::Cache* SkImageFilter::Cache::Create(size_t maxBytes) {
return SkNEW_ARGS(CacheImpl, (maxBytes));
}
+SK_DECLARE_STATIC_LAZY_PTR(SkImageFilter::Cache, cache, CreateCache);
+
SkImageFilter::Cache* SkImageFilter::Cache::Get() {
- SK_DECLARE_STATIC_LAZY_PTR(SkImageFilter::Cache, cache, CreateCache);
return cache.get();
}
« no previous file with comments | « src/core/SkGlyphCache.cpp ('k') | src/core/SkLazyPtr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698