Chromium Code Reviews| Index: src/core/SkMaskFilter.cpp |
| diff --git a/src/core/SkMaskFilter.cpp b/src/core/SkMaskFilter.cpp |
| index f062f135fdbebbd4f5016bfde05dc0a424e04ccb..adfed4109899dfda776e8b765fa393d02f8309ae 100644 |
| --- a/src/core/SkMaskFilter.cpp |
| +++ b/src/core/SkMaskFilter.cpp |
| @@ -349,10 +349,14 @@ bool SkMaskFilter::filterMaskGPU(GrContext* context, |
| if (!result) { |
| return false; |
| } |
| + SkAutoUnref aur(dst); |
| + SkImageInfo info; |
| resultBM->setConfig(srcBM.config(), dst->width(), dst->height()); |
| - resultBM->setPixelRef(SkNEW_ARGS(SkGrPixelRef, (dst)))->unref(); |
| - dst->unref(); |
| + if (resultBM->asImageInfo(&info)) { |
|
scroggo
2013/12/13 19:17:29
I think this should be if NOT asImageInfo.
reed1
2013/12/13 19:42:31
Done.
|
| + return false; |
| + } |
| + resultBM->setPixelRef(SkNEW_ARGS(SkGrPixelRef, (info, dst)))->unref(); |
| return true; |
| } |