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

Unified Diff: src/core/SkResourceCache.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/core/SkRecordDraw.cpp ('k') | src/core/SkScan_Path.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkResourceCache.cpp
diff --git a/src/core/SkResourceCache.cpp b/src/core/SkResourceCache.cpp
index 7ffdfffbaf25881276e64ddd5e5c9dfbce3da1bb..73f788cd172a7ac1e6e049a5ce246d2fff92eb64 100644
--- a/src/core/SkResourceCache.cpp
+++ b/src/core/SkResourceCache.cpp
@@ -222,7 +222,7 @@ const SkResourceCache::Rec* SkResourceCache::addAndLock(Rec* rec) {
SkASSERT(rec);
// See if we already have this key (racy inserts, etc.)
const Rec* existing = this->findAndLock(rec->getKey());
- if (NULL != existing) {
+ if (existing) {
SkDELETE(rec);
return existing;
}
@@ -242,7 +242,7 @@ void SkResourceCache::add(Rec* rec) {
SkASSERT(rec);
// See if we already have this key (racy inserts, etc.)
const Rec* existing = this->findAndLock(rec->getKey());
- if (NULL != existing) {
+ if (existing) {
SkDELETE(rec);
this->unlock(existing);
return;
@@ -414,9 +414,9 @@ void SkResourceCache::validate() const {
}
SkASSERT(NULL == fHead->fPrev);
- SkASSERT(NULL != fHead->fNext);
+ SkASSERT(fHead->fNext);
SkASSERT(NULL == fTail->fNext);
- SkASSERT(NULL != fTail->fPrev);
+ SkASSERT(fTail->fPrev);
size_t used = 0;
int count = 0;
« no previous file with comments | « src/core/SkRecordDraw.cpp ('k') | src/core/SkScan_Path.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698