Index: src/gpu/GrResourceCache2.cpp |
diff --git a/src/gpu/GrResourceCache2.cpp b/src/gpu/GrResourceCache2.cpp |
index a63bda8cc7af14477a7b2c8d7ec0e21bd2c90708..5f31bf010ef2fe03091f6c0683019c9ab559d5c4 100644 |
--- a/src/gpu/GrResourceCache2.cpp |
+++ b/src/gpu/GrResourceCache2.cpp |
@@ -33,7 +33,7 @@ GrContentKey::Domain GrContentKey::GenerateDomain() { |
static int32_t gDomain = INHERITED::kInvalidDomain + 1; |
int32_t domain = sk_atomic_inc(&gDomain); |
- if (kInvalidDomain == gDomain) { |
+ if (domain > SK_MaxU16) { |
SkFAIL("Too many Content Key Domains"); |
} |