Index: src/ports/SkOSFile_posix.cpp |
diff --git a/src/ports/SkOSFile_posix.cpp b/src/ports/SkOSFile_posix.cpp |
index b604c2190c548ae4817fa4f4daba64baf71eb885..58662f382f45050380d49c0f611f27ad5f8069d8 100644 |
--- a/src/ports/SkOSFile_posix.cpp |
+++ b/src/ports/SkOSFile_posix.cpp |
@@ -63,19 +63,19 @@ void sk_fmunmap(const void* addr, size_t length) { |
void* sk_fdmmap(int fd, size_t* size) { |
struct stat status; |
if (0 != fstat(fd, &status)) { |
- return NULL; |
+ return nullptr; |
} |
if (!S_ISREG(status.st_mode)) { |
- return NULL; |
+ return nullptr; |
} |
if (!SkTFitsIn<size_t>(status.st_size)) { |
- return NULL; |
+ return nullptr; |
} |
size_t fileSize = static_cast<size_t>(status.st_size); |
- void* addr = mmap(NULL, fileSize, PROT_READ, MAP_PRIVATE, fd, 0); |
+ void* addr = mmap(nullptr, fileSize, PROT_READ, MAP_PRIVATE, fd, 0); |
if (MAP_FAILED == addr) { |
- return NULL; |
+ return nullptr; |
} |
*size = fileSize; |
@@ -89,7 +89,7 @@ int sk_fileno(SkFILE* f) { |
void* sk_fmmap(SkFILE* f, size_t* size) { |
int fd = sk_fileno(f); |
if (fd < 0) { |
- return NULL; |
+ return nullptr; |
} |
return sk_fdmmap(fd, size); |
@@ -149,7 +149,7 @@ bool SkOSFile::Iter::next(SkString* name, bool getDir) { |
if (self.fDIR) { |
dirent* entry; |
- while ((entry = ::readdir(self.fDIR)) != NULL) { |
+ while ((entry = ::readdir(self.fDIR)) != nullptr) { |
struct stat s; |
SkString str(self.fPath); |