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

Unified Diff: src/core/SkDeque.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/SkColorTable.cpp ('k') | src/core/SkDistanceFieldGen.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkDeque.cpp
diff --git a/src/core/SkDeque.cpp b/src/core/SkDeque.cpp
index d210dcf20be14508689ad5bb39a7db1575db23ea..27f3efcba4bb448daaa8c007a748d15810717970 100644
--- a/src/core/SkDeque.cpp
+++ b/src/core/SkDeque.cpp
@@ -100,7 +100,7 @@ void* SkDeque::push_front() {
SkASSERT(NULL == fBack);
fFront = fBack = begin;
} else {
- SkASSERT(NULL != fBack);
+ SkASSERT(fBack);
fFront = begin;
}
@@ -141,7 +141,7 @@ void* SkDeque::push_back() {
SkASSERT(NULL == fFront);
fFront = fBack = end;
} else {
- SkASSERT(NULL != fFront);
+ SkASSERT(fFront);
fBack = end;
}
@@ -169,14 +169,14 @@ void SkDeque::pop_front() {
if (begin < fFrontBlock->fEnd) {
first->fBegin = begin;
- SkASSERT(NULL != first->fBegin);
+ SkASSERT(first->fBegin);
fFront = first->fBegin;
} else {
first->fBegin = first->fEnd = NULL; // mark as empty
if (NULL == first->fNext) {
fFront = fBack = NULL;
} else {
- SkASSERT(NULL != first->fNext->fBegin);
+ SkASSERT(first->fNext->fBegin);
fFront = first->fNext->fBegin;
}
}
@@ -203,14 +203,14 @@ void SkDeque::pop_back() {
if (end > last->fBegin) {
last->fEnd = end;
- SkASSERT(NULL != last->fEnd);
+ SkASSERT(last->fEnd);
fBack = last->fEnd - fElemSize;
} else {
last->fBegin = last->fEnd = NULL; // mark as empty
if (NULL == last->fPrev) {
fFront = fBack = NULL;
} else {
- SkASSERT(NULL != last->fPrev->fEnd);
+ SkASSERT(last->fPrev->fEnd);
fBack = last->fPrev->fEnd - fElemSize;
}
}
@@ -293,14 +293,14 @@ void SkDeque::Iter::reset(const SkDeque& d, IterStart startLoc) {
if (kFront_IterStart == startLoc) {
// initialize the iterator to start at the front
fCurBlock = d.fFrontBlock;
- while (NULL != fCurBlock && NULL == fCurBlock->fBegin) {
+ while (fCurBlock && NULL == fCurBlock->fBegin) {
fCurBlock = fCurBlock->fNext;
}
fPos = fCurBlock ? fCurBlock->fBegin : NULL;
} else {
// initialize the iterator to start at the back
fCurBlock = d.fBackBlock;
- while (NULL != fCurBlock && NULL == fCurBlock->fEnd) {
+ while (fCurBlock && NULL == fCurBlock->fEnd) {
fCurBlock = fCurBlock->fPrev;
}
fPos = fCurBlock ? fCurBlock->fEnd - fElemSize : NULL;
« no previous file with comments | « src/core/SkColorTable.cpp ('k') | src/core/SkDistanceFieldGen.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698