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

Unified Diff: src/effects/gradients/SkGradientShader.cpp

Issue 544233002: "NULL !=" = NULL (Closed) Base URL: https://skia.googlesource.com/skia.git@are
Patch Set: rebase Created 6 years, 3 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/effects/SkTableColorFilter.cpp ('k') | src/effects/gradients/SkLinearGradient.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/gradients/SkGradientShader.cpp
diff --git a/src/effects/gradients/SkGradientShader.cpp b/src/effects/gradients/SkGradientShader.cpp
index 3ac363568c5eeb6ddc9026e1b75e4d068c8bb32c..23c473fa9cd52c0f1a288d2a74dd05c928c77eb1 100644
--- a/src/effects/gradients/SkGradientShader.cpp
+++ b/src/effects/gradients/SkGradientShader.cpp
@@ -1150,7 +1150,7 @@ GrGradientEffect::GrGradientEffect(GrContext* ctx,
desc.fContext = ctx;
desc.fConfig = SkImageInfo2GrPixelConfig(bitmap.info());
fAtlas = GrTextureStripAtlas::GetAtlas(desc);
- SkASSERT(NULL != fAtlas);
+ SkASSERT(fAtlas);
// We always filter the gradient table. Each table is one row of a texture, always y-clamp.
GrTextureParams params;
@@ -1239,7 +1239,7 @@ int GrGradientEffect::RandomGradientParams(SkRandom* random,
SkScalar stop = 0.f;
for (int i = 0; i < outColors; ++i) {
colors[i] = random->nextU();
- if (NULL != *stops) {
+ if (*stops) {
(*stops)[i] = stop;
stop = i < outColors - 1 ? stop + random->nextUScalar1() * (1.f - stop) : 1.f;
}
« no previous file with comments | « src/effects/SkTableColorFilter.cpp ('k') | src/effects/gradients/SkLinearGradient.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698