Index: src/core/SkXfermode.cpp |
diff --git a/src/core/SkXfermode.cpp b/src/core/SkXfermode.cpp |
index 443aa194055861c89c3fadf74ca3c143629bd544..8a3218fcbd0087f0d264f5550412c8a6171acf9c 100644 |
--- a/src/core/SkXfermode.cpp |
+++ b/src/core/SkXfermode.cpp |
@@ -1258,7 +1258,7 @@ SkProcCoeffXfermode::SkProcCoeffXfermode(SkReadBuffer& buffer) : INHERITED(buffe |
SkFlattenable* SkProcCoeffXfermode::CreateProc(SkReadBuffer& buffer) { |
uint32_t mode32 = buffer.read32(); |
- if (!buffer.validate(mode32 >= SK_ARRAY_COUNT(gProcCoeffs))) { |
+ if (!buffer.validate(mode32 < SK_ARRAY_COUNT(gProcCoeffs))) { |
return NULL; |
} |
return SkXfermode::Create((SkXfermode::Mode)mode32); |