Index: src/effects/SkPerlinNoiseShader.cpp |
diff --git a/src/effects/SkPerlinNoiseShader.cpp b/src/effects/SkPerlinNoiseShader.cpp |
index b721296afe2d6c38cc75ea7cc5fdc99eded5a184..6e53253f292a5d55fb5911e3142ffd411c23a2be 100644 |
--- a/src/effects/SkPerlinNoiseShader.cpp |
+++ b/src/effects/SkPerlinNoiseShader.cpp |
@@ -967,7 +967,11 @@ bool SkPerlinNoiseShader::asFragmentProcessor(GrContext* context, const SkPaint& |
} |
SkAutoTUnref<SkColorFilter> cf(SkColorFilter::CreateModeFilter( |
clearColor, SkXfermode::kSrc_Mode)); |
- *fp = cf->asFragmentProcessor(context); |
+ SkTDArray<GrFragmentProcessor*> array; |
+ if (cf->asFragmentProcessors(context, &array)) { |
+ SkASSERT(1 == array.count()); // modecolorfilter only returns one |
+ *fp = array[0]; // transfer ownership to fp |
+ } |
return true; |
} |