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

Unified Diff: tests/DeferredCanvasTest.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 | « tests/ClipStackTest.cpp ('k') | tests/DequeTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/DeferredCanvasTest.cpp
diff --git a/tests/DeferredCanvasTest.cpp b/tests/DeferredCanvasTest.cpp
index b8b82b2e8329429c31a052f24af8871a74e4021a..61af550e202fe84ac7fb4b628db50bf62199ab58 100644
--- a/tests/DeferredCanvasTest.cpp
+++ b/tests/DeferredCanvasTest.cpp
@@ -681,7 +681,7 @@ static PixelPtr get_surface_ptr(SkSurface* surface, bool useGpu) {
static void TestDeferredCanvasSurface(skiatest::Reporter* reporter, GrContextFactory* factory) {
SkImageInfo imageSpec = SkImageInfo::MakeN32Premul(10, 10);
- bool useGpu = NULL != factory;
+ bool useGpu = SkToBool(factory);
int cnt;
#if SK_SUPPORT_GPU
if (useGpu) {
@@ -712,7 +712,7 @@ static void TestDeferredCanvasSurface(skiatest::Reporter* reporter, GrContextFac
{
surface = SkSurface::NewRaster(imageSpec);
}
- SkASSERT(NULL != surface);
+ SkASSERT(surface);
SkAutoTUnref<SkSurface> aur(surface);
SkAutoTUnref<SkDeferredCanvas> canvas(SkDeferredCanvas::Create(surface));
@@ -764,7 +764,7 @@ static void TestDeferredCanvasSetSurface(skiatest::Reporter* reporter, GrContext
SkImageInfo imageSpec = SkImageInfo::MakeN32Premul(10, 10);
SkSurface* surface;
SkSurface* alternateSurface;
- bool useGpu = NULL != factory;
+ bool useGpu = SkToBool(factory);
int cnt;
#if SK_SUPPORT_GPU
if (useGpu) {
@@ -796,8 +796,8 @@ static void TestDeferredCanvasSetSurface(skiatest::Reporter* reporter, GrContext
surface = SkSurface::NewRaster(imageSpec);
alternateSurface = SkSurface::NewRaster(imageSpec);
}
- SkASSERT(NULL != surface);
- SkASSERT(NULL != alternateSurface);
+ SkASSERT(surface);
+ SkASSERT(alternateSurface);
SkAutoTUnref<SkSurface> aur1(surface);
SkAutoTUnref<SkSurface> aur2(alternateSurface);
PixelPtr pixels1 = get_surface_ptr(surface, useGpu);
« no previous file with comments | « tests/ClipStackTest.cpp ('k') | tests/DequeTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698