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

Unified Diff: src/core/SkChunkAlloc.cpp

Issue 1316233002: Style Change: NULL->nullptr (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-27 (Thursday) 10:25:06 EDT Created 5 years, 4 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/SkCanvas.cpp ('k') | src/core/SkClipStack.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkChunkAlloc.cpp
diff --git a/src/core/SkChunkAlloc.cpp b/src/core/SkChunkAlloc.cpp
index 4a71c2d2c43576263d00b2aeeac16aef90d50e61..3f30276f1b36ed45884a0a30335b96ce8f8cd185 100644
--- a/src/core/SkChunkAlloc.cpp
+++ b/src/core/SkChunkAlloc.cpp
@@ -30,7 +30,7 @@ struct SkChunkAlloc::Block {
}
void reset() {
- fNext = NULL;
+ fNext = nullptr;
fFreeSize = this->blockSize();
fFreePtr = this->startOfData();
}
@@ -60,7 +60,7 @@ SkChunkAlloc::SkChunkAlloc(size_t minSize) {
minSize = MIN_CHUNKALLOC_BLOCK_SIZE;
}
- fBlock = NULL;
+ fBlock = nullptr;
fMinSize = minSize;
fChunkSize = fMinSize;
fTotalCapacity = 0;
@@ -75,7 +75,7 @@ SkChunkAlloc::~SkChunkAlloc() {
void SkChunkAlloc::reset() {
Block::FreeChain(fBlock);
- fBlock = NULL;
+ fBlock = nullptr;
fChunkSize = fMinSize; // reset to our initial minSize
fTotalCapacity = 0;
fTotalUsed = 0;
@@ -142,7 +142,7 @@ SkChunkAlloc::Block* SkChunkAlloc::addBlockIfNecessary(size_t bytes, AllocFailTy
if (!fBlock || bytes > fBlock->fFreeSize) {
Block* block = this->newBlock(bytes, ftype);
if (!block) {
- return NULL;
+ return nullptr;
}
#ifdef SK_DEBUG
if (fBlock) {
@@ -164,7 +164,7 @@ void* SkChunkAlloc::alloc(size_t bytes, AllocFailType ftype) {
Block* block = this->addBlockIfNecessary(bytes, ftype);
if (!block) {
- return NULL;
+ return nullptr;
}
char* ptr = block->fFreePtr;
« no previous file with comments | « src/core/SkCanvas.cpp ('k') | src/core/SkClipStack.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698