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

Unified Diff: src/gpu/GrGpuResource.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/gpu/GrGpu.cpp ('k') | src/gpu/GrInOrderDrawBuffer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrGpuResource.cpp
diff --git a/src/gpu/GrGpuResource.cpp b/src/gpu/GrGpuResource.cpp
index d29ab6d486059b03bb00b92ebdf03ea3eabc0774..a8d7bbf9f50f975d35229d8dee4efdc4d14817a3 100644
--- a/src/gpu/GrGpuResource.cpp
+++ b/src/gpu/GrGpuResource.cpp
@@ -22,9 +22,9 @@ GrGpuRef::~GrGpuRef() {
///////////////////////////////////////////////////////////////////////////////
static inline GrResourceCache2* get_resource_cache2(GrGpu* gpu) {
- SkASSERT(NULL != gpu);
- SkASSERT(NULL != gpu->getContext());
- SkASSERT(NULL != gpu->getContext()->getResourceCache2());
+ SkASSERT(gpu);
+ SkASSERT(gpu->getContext());
+ SkASSERT(gpu->getContext()->getResourceCache2());
return gpu->getContext()->getResourceCache2();
}
@@ -50,7 +50,7 @@ GrGpuResource::~GrGpuResource() {
}
void GrGpuResource::release() {
- if (NULL != fGpu) {
+ if (fGpu) {
this->onRelease();
get_resource_cache2(fGpu)->removeResource(this);
fGpu = NULL;
@@ -58,7 +58,7 @@ void GrGpuResource::release() {
}
void GrGpuResource::abandon() {
- if (NULL != fGpu) {
+ if (fGpu) {
this->onAbandon();
get_resource_cache2(fGpu)->removeResource(this);
fGpu = NULL;
@@ -66,7 +66,7 @@ void GrGpuResource::abandon() {
}
const GrContext* GrGpuResource::getContext() const {
- if (NULL != fGpu) {
+ if (fGpu) {
return fGpu->getContext();
} else {
return NULL;
@@ -74,7 +74,7 @@ const GrContext* GrGpuResource::getContext() const {
}
GrContext* GrGpuResource::getContext() {
- if (NULL != fGpu) {
+ if (fGpu) {
return fGpu->getContext();
} else {
return NULL;
« no previous file with comments | « src/gpu/GrGpu.cpp ('k') | src/gpu/GrInOrderDrawBuffer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698